You've already forked macports-base
mirror of
https://github.com/macports/macports-base.git
synced 2026-07-12 18:18:43 -07:00
ci: azure: Fix deployment condition
The source branch is in the Build.SourceBranch variable, which is not the same as variables.Build.SourceBranch - the former expects a variable named 'Build.SourceBranch', the latter expects 'Build' to be a dict that contains the key 'SourceBranch'. Apparently the former is the correct approach, and the latter just returns null.
This commit is contained in:
@@ -54,7 +54,7 @@ jobs:
|
||||
--exclude '/opt/local/var/macports/sip-workaround/?*' \
|
||||
-cjf "MacPorts.tar.bz2" \
|
||||
/opt/local
|
||||
condition: and(succeeded(), or(eq(variables.Build.SourceBranch, 'refs/heads/travis-ci'), startsWith(variables.Build.SourceBranch, 'refs/tags/v')))
|
||||
condition: and(succeeded(), or(eq(variables['Build.SourceBranch'], 'refs/heads/travis-ci'), startsWith(variables['Build.SourceBranch'], 'refs/tags/v')))
|
||||
displayName: "Prepare Deployment"
|
||||
- bash: |
|
||||
set -eu
|
||||
@@ -82,5 +82,5 @@ jobs:
|
||||
env:
|
||||
user: "macports-ci-env"
|
||||
pass: $(BINTRAY_API_TOKEN)
|
||||
condition: and(succeeded(), or(eq(variables.Build.SourceBranch, 'refs/heads/travis-ci'), startsWith(variables.Build.SourceBranch, 'refs/tags/v')))
|
||||
condition: and(succeeded(), or(eq(variables['Build.SourceBranch'], 'refs/heads/travis-ci'), startsWith(variables['Build.SourceBranch'], 'refs/tags/v')))
|
||||
displayName: "Deploy to bintray"
|
||||
|
||||
Reference in New Issue
Block a user