Skip to content

Commit ffa8a4a

Browse files
committed
ci: clean-deploy on tag and skip redundant verify
The two-step 'mvn verify' then 'mvn deploy -Prelease -DskipTests' on tag pushes leaves unsigned outputs in target/ from step 1; step 2 re-enters the lifecycle without a clean, which can leave artifact bytes out of sync with the .asc files produced by gpg:sign. beast3's multi-module build has no maven-assembly-plugin, so the jar/ sources/javadoc artifacts have been deterministic enough that v2.8.0-beta5 published successfully. The bug is latent and caused v1.3.0-beta1 of FLC to fail with 'Invalid signature' on the assembly zip and the sources and javadoc jars. Fix preventively here. Changes: - gate 'Build and test' to non-tag pushes (the deploy step now runs the full lifecycle including tests) - replace 'mvn deploy -Prelease -DskipTests' with 'mvn -Prelease clean deploy' so the release runs from a clean target/ The master-push GitHub Packages deploy is unchanged: snapshots are unsigned, so byte-mismatch is not a concern there.
1 parent 5f6de16 commit ffa8a4a

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

.github/workflows/ci-publish.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ jobs:
5151
mvn versions:set -DnewVersion=$VERSION -DgenerateBackupPoms=false
5252
5353
- name: Build and test
54+
if: "!startsWith(github.ref, 'refs/tags/v')"
5455
run: mvn verify
5556

5657
- name: Deploy all modules to GitHub Packages
@@ -61,7 +62,7 @@ jobs:
6162

6263
- name: Publish to Maven Central
6364
if: startsWith(github.ref, 'refs/tags/v')
64-
run: mvn deploy -Prelease -DskipTests
65+
run: mvn -Prelease clean deploy
6566
env:
6667
CENTRAL_USERNAME: ${{ secrets.CENTRAL_USERNAME }}
6768
CENTRAL_TOKEN: ${{ secrets.CENTRAL_TOKEN }}

0 commit comments

Comments
 (0)