Skip to content

Commit 37dbb3b

Browse files
authored
Merge pull request #57 from TrueNine/dev
v0.0.34
2 parents 4556580 + 4f0d190 commit 37dbb3b

1 file changed

Lines changed: 14 additions & 2 deletions

File tree

.github/workflows/maven-central-publish.yaml

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -341,19 +341,24 @@ jobs:
341341
rm -rf .gradle/ || true
342342
find . -name "build" -type d -exec rm -rf {} + || true
343343
344+
# Clean Maven local repository for this project's artifacts to prevent conflicts
345+
rm -rf ~/.m2/repository/io/github/truenine/ || true
346+
344347
# First clean everything
345348
./gradlew clean \
346349
--no-daemon \
347350
--no-parallel \
348351
--no-build-cache \
349352
--no-configuration-cache
350353
351-
# Then run dry publication
354+
# Then run dry publication with additional safeguards
352355
./gradlew publishToMavenLocal \
353356
--no-daemon \
354357
--no-parallel \
355358
--no-build-cache \
356359
--no-configuration-cache \
360+
--rerun-tasks \
361+
--max-workers=1 \
357362
-PsigningInMemoryKeyId="${{ secrets.GPG_KEY_ID }}" \
358363
-PsigningInMemoryKey="${{ secrets.GPG_PRIVATE_KEY }}" \
359364
-PsigningInMemoryKeyPassword="${{ secrets.GPG_PASSPHRASE }}"
@@ -459,6 +464,11 @@ jobs:
459464
rm -rf .gradle/ || true
460465
find . -name "build" -type d -exec rm -rf {} + || true
461466
467+
# Clean Maven local repository for this project's artifacts to prevent conflicts
468+
rm -rf ~/.m2/repository/io/github/truenine/ || true
469+
470+
echo "Cleaned build services and Maven local repository" >> $GITHUB_STEP_SUMMARY
471+
462472
echo "Starting clean publication process..." >> $GITHUB_STEP_SUMMARY
463473
464474
# First clean everything to ensure no stale artifacts
@@ -468,12 +478,14 @@ jobs:
468478
--no-build-cache \
469479
--no-configuration-cache
470480
471-
# Then publish with fresh state
481+
# Then publish with fresh state and additional safeguards
472482
./gradlew publishToMavenCentral \
473483
--no-daemon \
474484
--no-parallel \
475485
--no-build-cache \
476486
--no-configuration-cache \
487+
--rerun-tasks \
488+
--max-workers=1 \
477489
-PsigningInMemoryKeyId="${{ secrets.GPG_KEY_ID }}" \
478490
-PsigningInMemoryKey="${{ secrets.GPG_PRIVATE_KEY }}" \
479491
-PmavenCentralUsername="${{ secrets.MAVENCENTRAL_USERNAME }}" \

0 commit comments

Comments
 (0)