Skip to content

Commit 7557e72

Browse files
committed
release: 1.2.2b
1 parent 88ea2ff commit 7557e72

1 file changed

Lines changed: 25 additions & 4 deletions

File tree

.github/workflows/build.yml

Lines changed: 25 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,14 @@ jobs:
2828

2929
- name: Make gradlew executable
3030
run: chmod +x ./gradlew
31+
32+
- name: Validate Gradle wrapper
33+
uses: gradle/wrapper-validation-action@v2
3134

3235
- name: Setup Gradle
3336
uses: gradle/gradle-build-action@v3
37+
with:
38+
gradle-home-cache-cleanup: true
3439

3540
- name: Cache Gradle dependencies
3641
uses: actions/cache@v4
@@ -42,14 +47,26 @@ jobs:
4247
restore-keys: |
4348
${{ runner.os }}-gradle-
4449
50+
- name: Clean Gradle cache
51+
run: |
52+
rm -rf ~/.gradle/caches/*/executionHistory/
53+
rm -rf ~/.gradle/caches/*/fileHashes/
54+
rm -rf ~/.gradle/caches/*/fileContent/
55+
4556
- name: Build with Gradle
46-
run: ./gradlew clean shadowJar
57+
run: ./gradlew --no-daemon --stacktrace clean shadowJar
58+
59+
- name: Fallback build with Maven (if Gradle fails)
60+
if: failure()
61+
run: mvn clean package
4762

4863
- name: Upload build artifacts
4964
uses: actions/upload-artifact@v4
5065
with:
5166
name: CreativeRequests-Plugin
52-
path: build/libs/CreativeRequests-*.jar
67+
path: |
68+
build/libs/CreativeRequests-*.jar
69+
target/CreativeRequests-*.jar
5370
if-no-files-found: error
5471

5572
- name: Check commit message
@@ -69,7 +86,9 @@ jobs:
6986
if: steps.check_commit.outputs.is_release == 'true'
7087
uses: softprops/action-gh-release@v2
7188
with:
72-
files: build/libs/CreativeRequests-*.jar
89+
files: |
90+
build/libs/CreativeRequests-*.jar
91+
target/CreativeRequests-*.jar
7392
tag_name: v${{ steps.check_commit.outputs.version }}
7493
name: Release ${{ steps.check_commit.outputs.version }}
7594
draft: false
@@ -80,7 +99,9 @@ jobs:
8099
if: steps.check_commit.outputs.is_release != 'true'
81100
uses: softprops/action-gh-release@v2
82101
with:
83-
files: build/libs/CreativeRequests-*.jar
102+
files: |
103+
build/libs/CreativeRequests-*.jar
104+
target/CreativeRequests-*.jar
84105
tag_name: beta-${{ github.sha }}
85106
name: Beta Build ${{ steps.check_commit.outputs.version }}
86107
draft: false

0 commit comments

Comments
 (0)