mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-11-03 22:20:28 +03:00
nightly: GitLab URLs end in '.git' to avoid warning and redirects
warning: redirecting to https://gitlab.com/fdroid/fdroidclient-nightly.git/
This commit is contained in:
parent
98aaf1ba7c
commit
0a5f15dad7
2 changed files with 6 additions and 7 deletions
|
|
@ -325,14 +325,13 @@ def main():
|
|||
if 'CI_PROJECT_PATH' in os.environ and 'CI_PROJECT_URL' in os.environ:
|
||||
# we are in GitLab CI
|
||||
repo_git_base = os.getenv('CI_PROJECT_PATH') + NIGHTLY
|
||||
clone_url = os.getenv('CI_PROJECT_URL') + NIGHTLY
|
||||
base_url = f"{os.getenv('CI_PROJECT_URL')}{NIGHTLY}"
|
||||
clone_url = f'{base_url}.git' # avoid redirects while cloning
|
||||
repo_base = get_repo_base_url(
|
||||
clone_url, repo_git_base, force_type='gitlab.com'
|
||||
)
|
||||
servergitmirror = 'git@' + urlparse(clone_url).netloc + ':' + repo_git_base
|
||||
deploy_key_url = (
|
||||
f'{clone_url}/-/settings/repository#js-deploy-keys-settings'
|
||||
base_url, repo_git_base, force_type='gitlab.com'
|
||||
)
|
||||
servergitmirror = f'git@{urlparse(base_url).netloc}:{repo_git_base}.git'
|
||||
deploy_key_url = f'{base_url}/-/settings/repository#js-deploy-keys-settings'
|
||||
git_user_name = os.getenv('GITLAB_USER_NAME')
|
||||
git_user_email = os.getenv('GITLAB_USER_EMAIL')
|
||||
elif 'TRAVIS_REPO_SLUG' in os.environ:
|
||||
|
|
|
|||
|
|
@ -359,7 +359,7 @@ class NightlyTest(unittest.TestCase):
|
|||
'repo_keyalias': 'androiddebugkey',
|
||||
'repo_name': 'fdroid/test-nightly',
|
||||
'repo_url': 'https://gitlab.com/fdroid/test-nightly/-/raw/master/fdroid/repo',
|
||||
'servergitmirrors': [{"url": 'git@gitlab.com:fdroid/test-nightly'}],
|
||||
'servergitmirrors': [{"url": 'git@gitlab.com:fdroid/test-nightly.git'}],
|
||||
}
|
||||
with open(common.CONFIG_FILE) as fp:
|
||||
config = yaml.safe_load(fp)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue