@@ -2,14 +2,14 @@ name: Release - Feature Freeze Ceremony
22
33#
44# Feature Freeze
5- #
6- # prereqs:
5+ #
6+ # prereqs:
77# 0. needs approval from another person to run the action (environment)
88# 1. ensure the correct branch is used to execute the action
99# a. if the run was triggered from the `main` branch, the NEXT_VERSION must be a new minor (end with a .0)
1010# b. if NEXT_VERSION is a patch release, then the branch the action was triggered on must be a release branch: `^[0-9]+\.[0-9]+\.x$`
1111# 2. ensure the next version does not exist as tag yet
12- #
12+ #
1313# Tasks
1414# 0. bump minor -dev version in version.config on main, if and only if it's a .0 release
1515# 1. creates the release branch X.Y.x, if and if the branch does not exist yet
@@ -35,17 +35,17 @@ jobs:
3535 - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
3636 with :
3737 fetch-depth : 0
38-
38+
3939 - name : Check Release Conditions
4040 run : |
4141 NEXT_VERSION=$(head -1 version.config | cut -d ' ' -f 3 | cut -d '-' -f 1)
4242 RELEASE_BRANCH="${NEXT_VERSION/%.[0-9]/.x}"
43-
43+
4444 echo "Checking run conditions for release: $NEXT_VERSION" >> $GITHUB_STEP_SUMMARY
4545 echo "Current branch: ${{ github.ref_name }}" >> $GITHUB_STEP_SUMMARY
4646 echo "Expected release branch: $RELEASE_BRANCH" >> $GITHUB_STEP_SUMMARY
4747 echo "" >> $GITHUB_STEP_SUMMARY
48-
48+
4949 # Condition: version tag can not exist
5050 if git tag -l | grep -q "^$NEXT_VERSION$"; then
5151 echo "❌ \`$NEXT_VERSION\` tag already exists" >> $GITHUB_STEP_SUMMARY
@@ -111,7 +111,7 @@ jobs:
111111 # Only running for new minor releases
112112 #
113113 # -------------------------------------------------------
114-
114+
115115 # Bump minor in main for minor releases
116116 - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
117117 with :
@@ -139,7 +139,7 @@ jobs:
139139 --head $BRANCH \
140140 --label "release")
141141 echo "* ✅ minor version increase on main: $PR_URL" >> $GITHUB_STEP_SUMMARY
142-
142+
143143 # Create `2.XX.x` release branch of `main`
144144 # Release branch is a dependency for the next steps
145145 # only execute this step on .0 releases
@@ -172,7 +172,7 @@ jobs:
172172 env :
173173 GITHUB_TOKEN : ${{ secrets.ORG_AUTOMATION_TOKEN }}
174174 run : |
175- ./scripts/changelog/generate.sh
175+ ./scripts/changelog/generate.sh
176176 BODY=$(head -n 19 CHANGELOG.md | tail -n 20)
177177
178178 BRANCH="release/${{ env.NEXT_VERSION }}-changelog"
@@ -188,29 +188,3 @@ jobs:
188188 --head $BRANCH \
189189 --label "release,changelog")
190190 echo "* ✅ CHANGELOG: $PR_URL" >> $GITHUB_STEP_SUMMARY
191-
192- # Rework version.config and up & down grade scripts
193- - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
194- with :
195- ref : ${{ env.RELEASE_BRANCH }}
196- - name : Generate release artefacts
197- env :
198- GITHUB_TOKEN : ${{ secrets.ORG_AUTOMATION_TOKEN }}
199- run : |
200- ./scripts/release/build_release_artefacts.sh ${{ env.CURRENT_VERSION }} ${{ env.NEXT_VERSION }}
201-
202- BRANCH="release/${{ env.CURRENT_VERSION }}-${{ env.NEXT_VERSION }}"
203- git checkout -b $BRANCH
204- git add version.config sql/updates/*.sql sql/CMakeLists.txt
205- git commit -m "release artefacts from ${{ env.CURRENT_VERSION }} to ${{ env.NEXT_VERSION }}"
206- git push origin $BRANCH
207-
208- BODY="- CHANGELOG\n- set previous_version in version.config\n- adjust CMakeList.txt with up & down grade files"
209-
210- PR_URL=$(gh pr create \
211- --title "Release artefacts ${{ env.NEXT_VERSION }}" \
212- --body "${BODY//\\n/$\n}" \
213- --base ${{ env.RELEASE_BRANCH }} \
214- --head $BRANCH \
215- --label "release")
216- echo "* ✅ Release artefacts: $PR_URL" >> $GITHUB_STEP_SUMMARY
0 commit comments