Skip to content

Commit

Permalink
Add support for gitee.com
Browse files Browse the repository at this point in the history
  • Loading branch information
loyalpartner committed Dec 28, 2020
1 parent c27814a commit 871a51b
Show file tree
Hide file tree
Showing 4 changed files with 47 additions and 0 deletions.
6 changes: 6 additions & 0 deletions docs/forge.org
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,12 @@ also see [[*Getting Started]].
Bitbucket Hosts

- https://bitbucket.org

- Gitee

Gitee Hosts

- https://gitee.com

** Supported Semi-Forges
:PROPERTIES:
Expand Down
2 changes: 2 additions & 0 deletions lisp/forge-core.el
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@
"code.orgmode.org" forge-gogs-repository)
("bitbucket.org" "api.bitbucket.org/2.0"
"bitbucket.org" forge-bitbucket-repository)
("gitee.com" nil
"gitee.com" forge-gitee-repository)
;; Semi-Forges
("git.savannah.gnu.org" nil
"git.savannah.gnu.org" forge-cgit**-repository)
Expand Down
38 changes: 38 additions & 0 deletions lisp/forge-gitee.el
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
;;; forge-gitee.el --- Gitee support -*- lexical-binding: t -*-

;; Copyright (C) 2018-2020 Jonas Bernoulli

;; Author: Jonas Bernoulli <[email protected]>
;; Maintainer: Jonas Bernoulli <[email protected]>

;; Forge is free software; you can redistribute it and/or modify it
;; under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 3, or (at your option)
;; any later version.
;;
;; Forge is distributed in the hope that it will be useful, but WITHOUT
;; ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
;; or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
;; License for more details.
;;
;; You should have received a copy of the GNU General Public License
;; along with Forge. If not, see http://www.gnu.org/licenses.

;;; Code:

(require 'forge)

;;; Class

(defclass forge-gitee-repository (forge-unusedapi-repository)
((issues-url-format :initform "https://%h/%o/%n/issues")
(issue-url-format :initform "https://%h/%o/%n/issue/%i")
(pullreqs-url-format :initform "https://%h/%o/%n/pulls")
(pullreq-url-format :initform "https://%h/%o/%n/pulls/%i")
(commit-url-format :initform "https://%h/%o/%n/commit/%r")
(branch-url-format :initform "https://%h/%o/%n/tree/%r")
(remote-url-format :initform "https://%h/%o/%n")))

;;; _
(provide 'forge-gitee)
;;; forge-gitee.el ends here
1 change: 1 addition & 0 deletions lisp/forge.el
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
(require 'forge-github)
(require 'forge-gitlab)
(require 'forge-gitea)
(require 'forge-gitee)
(require 'forge-gogs)
(require 'forge-bitbucket)
(require 'forge-semi)
Expand Down

0 comments on commit 871a51b

Please sign in to comment.