gitlab: Upgrade to API v4

Signed-off-by: Xuanwo <xuanwo.cn@gmail.com>
This commit is contained in:
Xuanwo 2018-06-09 00:02:02 +08:00
parent f1c55296af
commit 9d32a25c55
1 changed files with 2 additions and 2 deletions

View File

@ -11,8 +11,8 @@ from ..sortversion import sort_version_keys
logger = structlog.get_logger(logger_name=__name__)
GITLAB_URL = 'https://%s/api/v3/projects/%s/repository/commits?ref_name=%s'
GITLAB_MAX_TAG = 'https://%s/api/v3/projects/%s/repository/tags'
GITLAB_URL = 'https://%s/api/v4/projects/%s/repository/commits?ref_name=%s'
GITLAB_MAX_TAG = 'https://%s/api/v4/projects/%s/repository/tags'
async def get_version(name, conf, **kwargs):
repo = urllib.parse.quote_plus(conf.get('gitlab'))