2424 with :
2525 ref : main
2626 fetch-depth : 0
27+ persist-credentials : false
2728
2829 - name : Compute CalVer version
2930 id : compute
3839 id : previous
3940 env :
4041 GH_TOKEN : ${{ github.token }}
42+ shell : flox activate -d flox/base -- bash -eo pipefail {0}
4143 run : |
4244 PREVIOUS_TAG=$(gh release list --json tagName \
4345 --jq '[.[] | select(.tagName | test("^[0-9]+\\.[0-9]+$"))] | .[0].tagName // ""')
6264 echo "version_id=$VERSION_ID" >> "$GITHUB_OUTPUT"
6365 echo "Jira version $VERSION → id $VERSION_ID"
6466
65- release-plugin-api :
66- needs : prepare
67- runs-on : self-hosted
68- permissions :
69- contents : write
70- steps :
71- - uses : actions/checkout@v4
72- with :
73- ref : main
74-
75- - name : Build plugin-api jar
76- run : |
77- flox activate -d flox/base -- \
78- ./gradlew --console=plain --no-daemon :plugin-api:createPluginApiJar
79-
80- - name : Build plugin-builder jar
81- run : |
82- flox activate -d flox/base -- \
83- ./gradlew --console=plain --no-daemon -p plugin-api/plugin-builder :jar
84-
85- - name : Stage plugin-api release assets
86- run : |
87- mkdir -p .release
88- cp plugin-api/build/libs/plugin-api-*.jar .release/plugin-api.jar
89- cp plugin-api/plugin-builder/build/libs/plugin-builder-*.jar .release/gradle-plugin.jar
90- ( cd .release && sha256sum plugin-api.jar gradle-plugin.jar > checksums.txt )
91- ls -la .release
92-
93- - name : Replace plugin-api-latest release
94- env :
95- GH_TOKEN : ${{ github.token }}
96- run : |
97- if gh release view plugin-api-latest >/dev/null 2>&1; then
98- gh release delete plugin-api-latest --cleanup-tag --yes
99- fi
100- gh release create plugin-api-latest \
101- --target "$GITHUB_SHA" \
102- --title "plugin-api (latest)" \
103- --notes "built from ${GITHUB_SHA} on $(date -u +'%Y-%m-%d %H:%M:%S UTC')" \
104- .release/plugin-api.jar \
105- .release/gradle-plugin.jar \
106- .release/checksums.txt
107-
10867 pull-apk :
10968 needs : prepare
11069 runs-on : self-hosted
12180 - uses : actions/checkout@v4
12281 with :
12382 ref : main
83+ persist-credentials : false
12484
12585 - name : Reset staging directory
12686 run : |
@@ -218,7 +178,7 @@ jobs:
218178 run : rm -rf "$STAGING_DIR"
219179
220180 release-codeonthego :
221- needs : [prepare, pull-apk, release-plugin-api ]
181+ needs : [prepare, pull-apk]
222182 runs-on : self-hosted
223183 permissions :
224184 contents : write
@@ -227,12 +187,14 @@ jobs:
227187 with :
228188 ref : main
229189 fetch-depth : 0
190+ persist-credentials : false
230191
231192 - name : Tag and create GitHub Release (idempotent)
232193 env :
233194 GH_TOKEN : ${{ github.token }}
234195 VERSION : ${{ needs.prepare.outputs.version }}
235196 PREVIOUS_TAG : ${{ needs.prepare.outputs.previous_tag }}
197+ shell : flox activate -d flox/base -- bash -eo pipefail {0}
236198 run : |
237199 if gh release view "$VERSION" >/dev/null 2>&1; then
238200 echo "Release $VERSION already exists; skipping creation."
@@ -304,6 +266,11 @@ jobs:
304266 contents : read
305267 actions : write
306268 steps :
269+ - uses : actions/checkout@v4
270+ with :
271+ ref : main
272+ persist-credentials : false
273+
307274 - name : Close Jira version (idempotent)
308275 env :
309276 JIRA_EMAIL : ${{ secrets.JIRA_EMAIL }}
@@ -329,6 +296,7 @@ jobs:
329296 env :
330297 GH_TOKEN : ${{ steps.app-token.outputs.token }}
331298 NEXT_VERSION : ${{ needs.prepare.outputs.next_version }}
299+ shell : flox activate -d flox/base -- bash -eo pipefail {0}
332300 run : |
333301 gh variable set NEXT_RELEASE_VERSION --body "$NEXT_VERSION" --repo "$GITHUB_REPOSITORY"
334302 echo "NEXT_RELEASE_VERSION set to $NEXT_VERSION"
0 commit comments