[d16-9] [CI][VSTS] Use the creds store in git for https. (#10536)

This commit is contained in:
VS MobileTools Engineering Service 2 2021-01-27 21:01:01 -08:00 коммит произвёл GitHub
Родитель fd1fc09999
Коммит 04bdcdaa8c
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
1 изменённых файлов: 11 добавлений и 0 удалений

Просмотреть файл

@ -28,6 +28,12 @@ steps:
- checkout: release-scripts
clean: true
- pwsh: |
rm -Rf "$HOME\.git-credentials"
git config --global credential.helper store
Set-Content -Path "$HOME\.git-credentials" -Value "https://$(GitHub.Token):x-oauth-basic@github.com`n" -NoNewline
displayName: 'Add git creds store'
- powershell: |
gci env: | format-table -autosize -wrap
displayName: 'Dump Environment'
@ -473,3 +479,8 @@ steps:
artifactName: HtmlReport-sim
continueOnError: true
condition: and(succeededOrFailed(), contains(variables['runTests.TESTS_RAN'], 'True')) # if tests did not run, there is nothing to do
- pwsh: |
rm -Rf "$HOME\.git-credentials"
displayName: 'Remove git creds store'
condition: always()