Skip to content

Commit 5e344e4

Browse files
committed
Refactor publish workflow: change build command to shadowJar and add timestamp generation for pre-release information
1 parent c61c167 commit 5e344e4

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

.github/workflows/publish-prerelease.yml

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,13 @@ jobs:
3838
${{ runner.os }}-gradle-
3939
4040
- name: Build project
41-
run: ./gradlew build
41+
run: ./gradlew shadowJar
4242

43-
- name: Publish JAR to pre-release
43+
- name: Generate timestamp
44+
id: timestamp
45+
run: echo "timestamp=$(date +'%Y%m%d-%H%M%S')" >> $GITHUB_OUTPUT
46+
47+
- name: Publish single pre-release
4448
uses: ncipollo/release-action@v1
4549
with:
4650
artifacts: "build/libs/*.jar"
@@ -49,6 +53,12 @@ jobs:
4953
body: |
5054
🚧 This is the latest build from the `develop` branch.
5155
Not intended for production use.
56+
57+
**Last Updated:** ${{ steps.timestamp.outputs.timestamp }}
58+
**Build Info:**
59+
- Branch: `${{ github.ref_name }}`
60+
- Commit: `${{ github.sha }}`
61+
- Build Time: `${{ steps.timestamp.outputs.timestamp }}`
5262
prerelease: true
5363
allowUpdates: true
5464
replacesArtifacts: true

0 commit comments

Comments
 (0)