BUILD-4733: update clone command to use a github access-token

This commit is contained in:
tomverin 2024-07-04 15:48:47 +02:00 committed by GitHub
parent abec878530
commit 8a20fdca5e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -155,7 +155,7 @@ def checkout_repo(repo):
git_url=f"https://github.com/SonarSource/{repo}"
token=os.getenv('GITHUB_TOKEN')
if token:
git_url=f"https://{token}@github.com/SonarSource/{repo}"
git_url=f"https://{token}:x-oauth-basic@github.com/SonarSource/{repo}"
if not os.path.exists(repo):
return Repo.clone_from(git_url, repo)
else: