diff options
| author | bors <bors@rust-lang.org> | 2022-06-05 12:31:26 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2022-06-05 12:31:26 +0000 |
| commit | fee3a459dd6aba8e34a5b99f0fbcb4218a1e2401 (patch) | |
| tree | 98e88f503bf4609b1eea99f02ef8ea34be3744ef /src/ci/shared.sh | |
| parent | 4322a785cc99ea5fc81dd7f5fc8ba7f7a64b08ef (diff) | |
| parent | 6523ef41da79f06c883f0572e068251ed4370a1e (diff) | |
Auto merge of #97756 - pietroalbini:pa-remove-azure-pipelines, r=Mark-Simulacrum
Remove Azure Pipelines configuration This PR removes the remaining Azure Pipelines configuration, now that we fully removed all the resources on the Azure side of things.
Diffstat (limited to 'src/ci/shared.sh')
| -rw-r--r-- | src/ci/shared.sh | 31 |
1 files changed, 7 insertions, 24 deletions
diff --git a/src/ci/shared.sh b/src/ci/shared.sh index 1f218bc8346..8a88c56194c 100644 --- a/src/ci/shared.sh +++ b/src/ci/shared.sh @@ -28,11 +28,7 @@ function retry { } function isCI { - [[ "${CI-false}" = "true" ]] || isAzurePipelines || isGitHubActions -} - -function isAzurePipelines { - [[ "${TF_BUILD-False}" = "True" ]] + [[ "${CI-false}" = "true" ]] || isGitHubActions } function isGitHubActions { @@ -63,9 +59,7 @@ function isCiBranch { fi name="$1" - if isAzurePipelines; then - [[ "${BUILD_SOURCEBRANCHNAME}" = "${name}" ]] - elif isGitHubActions; then + if isGitHubActions; then [[ "${GITHUB_REF}" = "refs/heads/${name}" ]] else echo "isCiBranch only works inside CI!" @@ -74,10 +68,7 @@ function isCiBranch { } function ciBaseBranch { - if isAzurePipelines; then - echo "unsupported on Azure Pipelines" - exit 1 - elif isGitHubActions; then + if isGitHubActions; then echo "${GITHUB_BASE_REF#refs/heads/}" else echo "ciBaseBranch only works inside CI!" @@ -86,9 +77,7 @@ function ciBaseBranch { } function ciCommit { - if isAzurePipelines; then - echo "${BUILD_SOURCEVERSION}" - elif isGitHubActions; then + if isGitHubActions; then echo "${GITHUB_SHA}" else echo "ciCommit only works inside CI!" @@ -97,9 +86,7 @@ function ciCommit { } function ciCheckoutPath { - if isAzurePipelines; then - echo "${BUILD_SOURCESDIRECTORY}" - elif isGitHubActions; then + if isGitHubActions; then echo "${GITHUB_WORKSPACE}" else echo "ciCheckoutPath only works inside CI!" @@ -114,9 +101,7 @@ function ciCommandAddPath { fi path="$1" - if isAzurePipelines; then - echo "##vso[task.prependpath]${path}" - elif isGitHubActions; then + if isGitHubActions; then echo "${path}" >> "${GITHUB_PATH}" else echo "ciCommandAddPath only works inside CI!" @@ -132,9 +117,7 @@ function ciCommandSetEnv { name="$1" value="$2" - if isAzurePipelines; then - echo "##vso[task.setvariable variable=${name}]${value}" - elif isGitHubActions; then + if isGitHubActions; then echo "${name}=${value}" >> "${GITHUB_ENV}" else echo "ciCommandSetEnv only works inside CI!" |
