From 6999f152047bf23542f1321e22b1f41e2254258a Mon Sep 17 00:00:00 2001 From: Wez Furlong Date: Sun, 23 Jun 2019 09:20:40 -0700 Subject: [PATCH] really fix ' issue, schedule a nightly pre-release --- azure-pipelines.yml | 32 ++++++++++++++++++++++++++------ ci/deploy.sh | 3 +++ 2 files changed, 29 insertions(+), 6 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index cbfc1123c5c..502ee4770e8 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -1,3 +1,5 @@ +# vim:et:sw=2:ts=2: + trigger: branches: include: ['master'] @@ -142,23 +144,41 @@ jobs: condition: ne( variables['Agent.OS'], 'Windows_NT' ) - script: cargo build --release --all displayName: Build in release mode - - script: bash ci/deploy.sh + - bash: ci/deploy.sh displayName: Packaging - task: GithubRelease@0 - condition: succeeded() - #condition: and(succeeded(), startsWith(variables['Build.SourceBranch'], 'refs/tags/')) + condition: and(succeeded(), ne(variables['BUILD_REASON'], 'Schedule'), startsWith(variables['Build.SourceBranch'], 'refs/tags/')) + displayName: Release from tag + inputs: + gitHubConnection: release + repositoryName: wez/wezterm + action: edit + target: $(build.sourceVersion) + tagSource: manual + tag: $(wezterm.tagname) + assets: | + $(Build.SourcesDirectory)/*.zip + $(Build.SourcesDirectory)/*.deb + title: $(wezterm.tagname) + assetUploadMode: replace + addChangeLog: false + isPreRelease: false + isDraft: false + - task: GithubRelease@0 + condition: and(succeeded(), eq(variables['BUILD_REASON'], 'Schedule')) + displayName: Release from nightly build inputs: gitHubConnection: release repositoryName: wez/wezterm action: edit target: $(build.sourceVersion) tagSource: manual - tag: azure-test-$(wezterm.tagname) + tag: nightly-$(wezterm.tagname) assets: | $(Build.SourcesDirectory)/*.zip $(Build.SourcesDirectory)/*.deb - title: "Azure test: $(wezterm.tagname)" + title: "Nightly Pre-Release: $(wezterm.tagname)" assetUploadMode: replace addChangeLog: false isPreRelease: true - isDraft: true + isDraft: false diff --git a/ci/deploy.sh b/ci/deploy.sh index 7a20d479dbd..e69ea4ffc61 100755 --- a/ci/deploy.sh +++ b/ci/deploy.sh @@ -18,7 +18,10 @@ TAG_NAME=${TAG_NAME:-$(git describe --tags)} TAG_NAME=${TAG_NAME:-$(date +'%Y%m%d-%H%M%S')-$(git log --format=%h -1)} # Emit the tagname variable for azure to pick up +# https://docs.microsoft.com/en-us/azure/devops/pipelines/troubleshooting?view=azure-devops#variables-having--single-quote-appended +set +x echo "##vso[task.setvariable variable=wezterm.tagname]$TAG_NAME" +set -x HERE=$(pwd)