Skip to content

Commit

Permalink
PR Comments
Browse files Browse the repository at this point in the history
  • Loading branch information
willdavsmith committed Jan 26, 2024
1 parent cd736f7 commit 0202709
Showing 1 changed file with 8 additions and 12 deletions.
20 changes: 8 additions & 12 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ on:

env:
GITHUB_TOKEN: ${{ secrets.GH_RAD_CI_BOT_PAT }}
IS_WORKFLOW_STOPPED: false

jobs:
generate_release_note:
Expand Down Expand Up @@ -178,37 +177,34 @@ jobs:
})
if (data.name == '${{ steps.get-version.outputs.release-branch-name }}') {
echo "Release branch ${{ steps.get-version.outputs.release-branch-name }} already exists."
return 'true'
} else {
echo "Release branch ${{ steps.get-version.outputs.release-branch-name }} does not exist."
return 'false'
}
- name: Stop workflow if release branch exists and the event is a push to main
if: steps.release-branch-exists == 'true' && github.ref == 'refs/heads/main' && github.event_name == 'push'
run: |
echo "Release branch ${{ steps.get-version.outputs.release-branch-name }} already exists. Stop the workflow."
echo "IS_WORKFLOW_STOPPED=true" >> $GITHUB_ENV
- name: Generate release summary
if: env.IS_WORKFLOW_STOPPED == 'false'
if: steps.release-branch-exists.outputs.result == 'false'
run: |
echo "## Release" >> $GITHUB_STEP_SUMMARY
echo "* Release driver: $GITHUB_ACTOR ">> $GITHUB_STEP_SUMMARY
echo "* Supported versions: ${{ steps.get-supported-versions.outputs.result }}" >> $GITHUB_STEP_SUMMARY
echo "* Desired release tag: ${{ steps.get-version.outputs.release-version }}" >> $GITHUB_STEP_SUMMARY
echo "* Desired release branch: ${{ steps.get-version.outputs.release-branch-name }}" >> $GITHUB_STEP_SUMMARY
echo "* Release date: $(date)" >> $GITHUB_STEP_SUMMARY
echo "* Release date: $(date)" >> $GITHUB_STEP_SUMMA`RY
- name: Release radius-project/radius version ${{ steps.get-version.outputs.release-version }}
if: success() && env.IS_WORKFLOW_STOPPED == 'false'
if: success() && steps.release-branch-exists.outputs.result == 'false'
run: |
./radius/.github/scripts/release-create-tag-and-branch.sh radius ${{ steps.get-version.outputs.release-version }} ${{ steps.get-version.outputs.release-branch-name }}
- name: Release radius-project/bicep version ${{ steps.get-version.outputs.release-version }}
if: success() && env.IS_WORKFLOW_STOPPED == 'false'
if: success() && steps.release-branch-exists.outputs.result == 'false'
run: |
./radius/.github/scripts/release-create-tag-and-branch.sh bicep ${{ steps.get-version.outputs.release-version }} ${{ steps.get-version.outputs.release-branch-name }}
- name: Release radius-project/deployment-engine version ${{ steps.get-version.outputs.release-version }}
if: success() && env.IS_WORKFLOW_STOPPED == 'false'
if: success() && steps.release-branch-exists.outputs.result == 'false'
run: |
./radius/.github/scripts/release-create-tag-and-branch.sh deployment-engine ${{ steps.get-version.outputs.release-version }} ${{ steps.get-version.outputs.release-branch-name }}
- name: Release radius-project/recipes version ${{ steps.get-version.outputs.release-version }}
if: success() && env.IS_WORKFLOW_STOPPED == 'false'
if: success() && steps.release-branch-exists.outputs.result == 'false'
run: |
./radius/.github/scripts/release-create-tag-and-branch.sh recipes ${{ steps.get-version.outputs.release-version }} ${{ steps.get-version.outputs.release-branch-name }}

0 comments on commit 0202709

Please sign in to comment.