From 74aee09c06cf05dc9ce339ece92c8f7bac5e1245 Mon Sep 17 00:00:00 2001 From: gjsjohnmurray Date: Thu, 27 Jan 2022 04:15:39 +0000 Subject: [PATCH] Another attempt at the release CI fix --- .github/workflows/main.yml | 25 ++++++++++--------------- .github/workflows/prerelease.yml | 25 ++++++++++--------------- CHANGELOG.md | 2 +- package.json | 2 +- 4 files changed, 22 insertions(+), 32 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 5f31f15..2197f97 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -26,9 +26,18 @@ jobs: outputs: name: ${{ steps.set-version.outputs.name }} version: ${{ steps.set-version.outputs.version }} + taggedbranch: ${{ steps.find-branch.outputs.taggedbranch }} steps: - uses: actions/checkout@v2 - run: git fetch --depth=1 origin +refs/tags/*:refs/tags/* + - name: Find which branch the release tag points at + id: find-branch + if: github.event_name == 'release' && runner.os == 'Windows' + shell: bash + run: | + set -x + TAGGEDBRANCH=$(git for-each-ref --points-at=${{github.sha}} --format='%(refname:lstrip=2)' refs/heads/) + echo ::set-output name=taggedbranch::$TAGGEDBRANCH - name: Set an output id: set-version if: runner.os == 'Windows' @@ -100,22 +109,8 @@ jobs: asset_path: ${{ needs.build.outputs.name }}.vsix asset_name: ${{ needs.build.outputs.name }}.vsix asset_content_type: application/zip - get_tagged_branch: - if: github.event_name == 'release' - runs-on: windows-latest - needs: build - outputs: - taggedbranch: ${{ steps.find-branch.outputs.taggedbranch }} - steps: - - name: Find which branch the release tag points at - id: find-branch - shell: bash - run: | - set -x - TAGGEDBRANCH=$(git for-each-ref --points-at=${{github.sha}} --format='%(refname:lstrip=2)' refs/heads/) - echo ::set-output name=taggedbranch::$TAGGEDBRANCH publish: - needs: get_tagged_branch + needs: build if: github.event_name == 'release' && needs.find-branch.outputs.taggedbranch == 'master' runs-on: windows-latest steps: diff --git a/.github/workflows/prerelease.yml b/.github/workflows/prerelease.yml index bbb268b..7afdc7a 100644 --- a/.github/workflows/prerelease.yml +++ b/.github/workflows/prerelease.yml @@ -26,9 +26,18 @@ jobs: outputs: name: ${{ steps.set-version.outputs.name }} version: ${{ steps.set-version.outputs.version }} + taggedbranch: ${{ steps.find-branch.outputs.taggedbranch }} steps: - uses: actions/checkout@v2 - run: git fetch --depth=1 origin +refs/tags/*:refs/tags/* + - name: Find which branch the release tag points at + id: find-branch + if: github.event_name == 'release' && runner.os == 'Windows' + shell: bash + run: | + set -x + TAGGEDBRANCH=$(git for-each-ref --points-at=${{github.sha}} --format='%(refname:lstrip=2)' refs/heads/) + echo ::set-output name=taggedbranch::$TAGGEDBRANCH - name: Set an output id: set-version if: runner.os == 'Windows' @@ -102,22 +111,8 @@ jobs: asset_path: ${{ needs.build.outputs.name }}.vsix asset_name: ${{ needs.build.outputs.name }}.vsix asset_content_type: application/zip - get_tagged_branch: - if: github.event_name == 'release' - runs-on: windows-latest - needs: build - outputs: - taggedbranch: ${{ steps.find-branch.outputs.taggedbranch }} - steps: - - name: Find which branch the release tag points at - id: find-branch - shell: bash - run: | - set -x - TAGGEDBRANCH=$(git for-each-ref --points-at=${{github.sha}} --format='%(refname:lstrip=2)' refs/heads/) - echo ::set-output name=taggedbranch::$TAGGEDBRANCH publish: - needs: get_tagged_branch + needs: build if: github.event_name == 'release' && needs.find-branch.outputs.taggedbranch == 'prerelease' runs-on: windows-latest steps: diff --git a/CHANGELOG.md b/CHANGELOG.md index 18bdafc..1ab3073 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,4 @@ -## 3.1.2022012603 (26-Jan-2022 pre-release) +## 3.1.2022012604 (26-Jan-2022 pre-release) * Update README. * Automate pre-release publication to Marketplace. diff --git a/package.json b/package.json index c7eb905..793b64d 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "servermanager", "displayName": "InterSystems Server Manager", - "version": "3.1.2022012603", + "version": "3.1.2022012604", "preview": true, "publisher": "intersystems-community", "description": "Define connections to InterSystems servers. Browse and manage those servers.",