diff --git a/.github/workflows/build-1204.yml b/.github/workflows/build-1204.yml index e4b7795f0..46f76fbf1 100644 --- a/.github/workflows/build-1204.yml +++ b/.github/workflows/build-1204.yml @@ -3,6 +3,8 @@ name: Build Leaf 1.20.4 on: push: branches: [ "ver/1.20.4" ] + pull_request: + branches: [ "ver/1.20.4" ] jobs: build: @@ -31,6 +33,7 @@ jobs: run: mv build/libs/leaf-paperclip-1.20.4-R0.1-SNAPSHOT-reobf.jar ./leaf-1.20.4.jar - name: Publish API + if: github.event_name != 'pull_request' run: | echo "GITHUB_USERNAME=Leaf" >> $GITHUB_ENV export GITHUB_USERNAME=Leaf @@ -46,7 +49,7 @@ jobs: path: ./leaf-1.20.4.jar - name: Release Leaf - if: contains(github.event.commits[0].message, '[Release]') + if: github.event_name != 'pull_request' uses: marvinpinto/action-automatic-releases@master with: title: "Leaf 1.20.4" diff --git a/.github/workflows/pr-1204.yml b/.github/workflows/pr-1204.yml deleted file mode 100644 index 05196323c..000000000 --- a/.github/workflows/pr-1204.yml +++ /dev/null @@ -1,37 +0,0 @@ -name: Build Leaf 1.20.4 - Pull Request - -on: - pull_request: - branches: [ "ver/1.20.4" ] - -jobs: - build: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@main - - uses: gradle/wrapper-validation-action@main - - name: Set up JDK - uses: graalvm/setup-graalvm@main - with: - java-version: 17 - github-token: "${{ secrets.GITHUB_TOKEN }}" - cache: gradle - - - name: Grant execute permission for gradlew - run: chmod +x gradlew - - name: Configure Git - run: git config --global user.email "no-reply@github.com" && git config --global user.name "Github Actions" - - - name: Apply patches - run: ./gradlew -Dorg.gradle.jvmargs="-Dgraal.CompilerConfiguration=enterprise -Dgraal.UsePriorityInlining=true -Dgraal.Vectorization=true -Dgraal.OptDuplication=true --add-modules jdk.incubator.vector" applyPatches --stacktrace --no-daemon - - name: Create ReobfPaperclipJar - run: ./gradlew -Dorg.gradle.jvmargs="-Dgraal.CompilerConfiguration=enterprise -Dgraal.UsePriorityInlining=true -Dgraal.Vectorization=true -Dgraal.OptDuplication=true --add-modules jdk.incubator.vector" createReobfPaperclipJar --stacktrace --no-daemon - - - name: Rename Paperclip Jar - run: mv build/libs/leaf-paperclip-1.20.4-R0.1-SNAPSHOT-reobf.jar ./leaf-1.20.4.jar - - - name: Upload Leaf - uses: actions/upload-artifact@main - with: - name: Leaf 1.20.4 - path: ./leaf-1.20.4.jar