-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathsettings.py
58 lines (47 loc) · 1.42 KB
/
settings.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
# -*- coding: utf-8 -*-
"""
@author: hsowan <[email protected]>
@date: 2020/2/10
"""
import os
# type Git服务器类型, 例如: gitee, github, gitlab, gitea, gogs, coding, 必填
# username 所在Git服务器的用户名, 必填
# token 用户所在Git服务器的授权令牌, 必填
# url Git服务器的访问地址, 例如: https://git.example.com (包括具体协议: http/https)
# 需要设置url的Git服务器有: gitlab, gitea, gogs, 其他Git服务器默认为空即可
# 源Git服务器配置
SOURCE_GIT = {
'type': '',
'username': '',
'token': '',
'url': ''
}
# 目的Git服务器配置
DEST_GIT = {
'type': 'gitlab',
'username': 'hsowan',
'token': '8MUV39-3fHTyn5-Vf2n6',
'url': 'https://git.ncucoder.com'
}
# 支持的Git服务器
SUPPORT_GITS = ['gitlab', 'github', 'gitee', 'gitea', 'coding', 'gogs', 'gf']
# 仓库暂存目录
TEMP_DIR = os.path.join(os.path.dirname(__file__), '.repos')
# GitLab
GITLAB_API_VERSION = '/api/v4'
# GitHub
# 暂不支持GitHub Enterprise
GITHUB_API = 'https://api.github.com/graphql'
GITHUB_SSH_PREFIX = '[email protected]:'
# 码云
GITEE_API = 'https://gitee.com/api/v5'
GITEE_SSH_PREFIX = '[email protected]:'
# Coding
# 暂不支持私有部署
CODING_SSH_PREFIX = '[email protected]:'
# Gitea/Gogs
GITEA_API_VERSION = '/api/v1'
# 腾讯工蜂
# 私有化部署请修改地址
GF_SSH_PREFIX = '[email protected]'
GF_API = 'https://code.tencent.com/api/v3'