From 665a14cd425bdd4a07e670d8df0facf3d4ca5a33 Mon Sep 17 00:00:00 2001 From: Julien Ponge Date: Wed, 29 May 2024 10:50:58 +0200 Subject: [PATCH] ci: cleanup workflows --- .build/justfile-for-release | 12 ++++++------ .github/workflows/build-main.yml | 12 ++++++------ .github/workflows/push-release-to-maven-central.yml | 8 ++++---- .github/workflows/release.yml | 8 ++++---- 4 files changed, 20 insertions(+), 20 deletions(-) diff --git a/.build/justfile-for-release b/.build/justfile-for-release index 9c8aed535..b01f1dc3e 100644 --- a/.build/justfile-for-release +++ b/.build/justfile-for-release @@ -24,11 +24,11 @@ pre-release: init-git @echo "Pre-release verifications" jbang .build/PreRelease.java --token=${RELEASE_TOKEN} --release-version=${RELEASE_VERSION} @echo "Bump project version to ${RELEASE_VERSION}" - ./mvnw --settings .build/maven-ci-settings.xml --batch-mode --no-transfer-progress versions:set -DnewVersion=${RELEASE_VERSION} -DgenerateBackupPoms=false - ./mvnw --settings .build/maven-ci-settings.xml --batch-mode --no-transfer-progress versions:set -DnewVersion=${RELEASE_VERSION} -DgenerateBackupPoms=false -pl bom + ./mvnw --batch-mode --no-transfer-progress versions:set -DnewVersion=${RELEASE_VERSION} -DgenerateBackupPoms=false + ./mvnw --batch-mode --no-transfer-progress versions:set -DnewVersion=${RELEASE_VERSION} -DgenerateBackupPoms=false -pl bom jbang .build/UpdateDocsAttributesFiles.java --mutiny-version=${RELEASE_VERSION} @echo "Check that the project builds (no tests)" - ./mvnw --settings .build/maven-ci-settings.xml --batch-mode --no-transfer-progress clean install -Prelease -DskipTests + ./mvnw --batch-mode --no-transfer-progress clean install -Prelease -DskipTests @echo "Bump workshop examples to ${RELEASE_VERSION}" .build/update-workshop-target-version.sh "${RELEASE_VERSION}" @echo "Check that the website builds" @@ -41,10 +41,10 @@ release: pre-release git commit -am "chore(release): release Mutiny ${RELEASE_VERSION}" git push @echo "Call JReleaser" - ./mvnw -settings .build/maven-ci-settings.xml --batch-mode --no-transfer-progress -Pjreleaser jreleaser:full-release -pl :mutiny-project + ./mvnw --batch-mode --no-transfer-progress -Pjreleaser jreleaser:full-release -pl :mutiny-project @echo "Bump to 999-SNAPSHOT and push upstream" - ./mvnw --settings .build/maven-ci-settings.xml --batch-mode --no-transfer-progress versions:set -DnewVersion=999-SNAPSHOT -DgenerateBackupPoms=false - ./mvnw --settings .build/maven-ci-settings.xml --batch-mode --no-transfer-progress versions:set -DnewVersion=999-SNAPSHOT -DgenerateBackupPoms=false -pl bom + ./mvnw --batch-mode --no-transfer-progress versions:set -DnewVersion=999-SNAPSHOT -DgenerateBackupPoms=false + ./mvnw --batch-mode --no-transfer-progress versions:set -DnewVersion=999-SNAPSHOT -DgenerateBackupPoms=false -pl bom git commit -am "chore(release): set development version to 999-SNAPSHOT" git push diff --git a/.github/workflows/build-main.yml b/.github/workflows/build-main.yml index 19fee17b2..481f0518f 100644 --- a/.github/workflows/build-main.yml +++ b/.github/workflows/build-main.yml @@ -23,21 +23,21 @@ jobs: server-id: 'oss.sonatype' server-username: 'MAVEN_DEPLOY_USERNAME' server-password: 'MAVEN_DEPLOY_TOKEN' - gpg-private-key: ${{secrets.MAVEN_GPG_PRIVATE_KEY}} + gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} gpg-passphrase: 'MAVEN_GPG_PASSPHRASE' - name: Install just uses: taiki-e/install-action@just - name: Test and deploy snapshots env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - MAVEN_DEPLOY_USERNAME: ${{secrets.MAVEN_DEPLOY_USERNAME}} - MAVEN_DEPLOY_TOKEN: ${{secrets.MAVEN_DEPLOY_TOKEN}} - MAVEN_GPG_PASSPHRASE: ${{secrets.MAVEN_GPG_PASSPHRASE}} + MAVEN_DEPLOY_USERNAME: ${{ secrets.MAVEN_DEPLOY_USERNAME }} + MAVEN_DEPLOY_TOKEN: ${{ secrets.MAVEN_DEPLOY_TOKEN }} + MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }} run: | VERSION=$(./mvnw -q exec:exec -Dexec.executable=echo -Dexec.args='${project.version}' -pl :mutiny-project) if [[ ${VERSION} == *SNAPSHOT ]]; then - # echo "🚀 Run the tests" - # ./mvnw --no-transfer-progress -s .build/maven-ci-settings.xml -B clean verify + echo "🚀 Run the tests" + ./mvnw --no-transfer-progress -s .build/maven-ci-settings.xml -B clean verify echo "🚀 Deploy the snapshots" just -f .build/justfile-for-release -d . deploy-to-maven-central else diff --git a/.github/workflows/push-release-to-maven-central.yml b/.github/workflows/push-release-to-maven-central.yml index 920c58f6b..46bafd1a3 100644 --- a/.github/workflows/push-release-to-maven-central.yml +++ b/.github/workflows/push-release-to-maven-central.yml @@ -20,13 +20,13 @@ jobs: server-id: 'oss.sonatype' server-username: 'MAVEN_DEPLOY_USERNAME' server-password: 'MAVEN_DEPLOY_TOKEN' - gpg-private-key: ${{secrets.MAVEN_GPG_PRIVATE_KEY}} + gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} gpg-passphrase: 'MAVEN_GPG_PASSPHRASE' - name: Install just uses: taiki-e/install-action@just - name: Deploy to Maven Central env: - MAVEN_DEPLOY_USERNAME: ${{secrets.MAVEN_DEPLOY_USERNAME}} - MAVEN_DEPLOY_TOKEN: ${{secrets.MAVEN_DEPLOY_TOKEN}} - MAVEN_GPG_PASSPHRASE: ${{secrets.MAVEN_GPG_PASSPHRASE}} + MAVEN_DEPLOY_USERNAME: ${{ secrets.MAVEN_DEPLOY_USERNAME }} + MAVEN_DEPLOY_TOKEN: ${{ secrets.MAVEN_DEPLOY_TOKEN }} + MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }} run: just -f .build/justfile-for-release -d . deploy-to-maven-central diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ad98206a8..704de0db4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -47,7 +47,7 @@ jobs: server-id: 'oss.sonatype' server-username: 'MAVEN_DEPLOY_USERNAME' server-password: 'MAVEN_DEPLOY_TOKEN' - gpg-private-key: ${{secrets.MAVEN_GPG_PRIVATE_KEY}} + gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} gpg-passphrase: 'MAVEN_GPG_PASSPHRASE' - name: Install just uses: taiki-e/install-action@just @@ -61,9 +61,9 @@ jobs: run: .build/install-mkdocs-deps.sh - name: Perform the release steps env: - MAVEN_DEPLOY_USERNAME: ${{secrets.MAVEN_DEPLOY_USERNAME}} - MAVEN_DEPLOY_TOKEN: ${{secrets.MAVEN_DEPLOY_TOKEN}} - MAVEN_GPG_PASSPHRASE: ${{secrets.MAVEN_GPG_PASSPHRASE}} + MAVEN_DEPLOY_USERNAME: ${{ secrets.MAVEN_DEPLOY_USERNAME }} + MAVEN_DEPLOY_TOKEN: ${{ secrets.MAVEN_DEPLOY_TOKEN }} + MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }} run: | curl -s "https://get.sdkman.io" | bash source ~/.sdkman/bin/sdkman-init.sh && sdk install jbang