Skip to content

Commit

Permalink
ci(maven): use script for releasing snapshots (#397)
Browse files Browse the repository at this point in the history
  • Loading branch information
ebaron authored May 14, 2024
1 parent bca8026 commit d43c082
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/push-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,5 @@ jobs:
uses: ./.github/workflows/maven-central-publish.yml
secrets: inherit
with:
publish-cmd: './mvnw -Prelease deploy jreleaser:deploy'
publish-cmd: './release-snapshot.sh'
if: ${{ github.repository_owner == 'cryostatio' && endsWith(needs.get-version.outputs.project-version, '-SNAPSHOT') }}
11 changes: 11 additions & 0 deletions release-snapshot.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/bin/bash
set -euo pipefail
IFS=$'\n\t'

echo "📦 Staging artifacts..."
./mvnw --batch-mode --no-transfer-progress -Ppublication -DskipTests=true -Dskip.spotless=true

echo "🚀 Releasing..."
./mvnw --batch-mode --no-transfer-progress -Prelease jreleaser:deploy

echo "🎉 Done!"

0 comments on commit d43c082

Please sign in to comment.