Skip to content

Commit

Permalink
fix workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
IThundxr committed Jun 21, 2024
1 parent b9d70de commit 2f5e0e3
Show file tree
Hide file tree
Showing 4 changed files with 54 additions and 34 deletions.
19 changes: 17 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,23 @@ jobs:
- name: Checkout Repository
uses: actions/checkout@v4

- name: Setup
uses: ./.github/workflows/setup.yml
- name: Setup Java
run: echo "JAVA_HOME=$JAVA_HOME_17_X64" >> "$GITHUB_ENV"

- name: Loom Cache
uses: actions/cache@v4
with:
path: "**/.gradle/loom-cache"
key: "${{ runner.os }}-gradle-${{ hashFiles('**/libs.versions.*', '**/*.gradle*', '**/gradle-wrapper.properties') }}"
restore-keys: "${{ runner.os }}-gradle-"

- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
with:
gradle-home-cache-cleanup: true

- name: Validate Gradle Wrapper Integrity
uses: gradle/wrapper-validation-action@v2

- name: Build
run: ./gradlew build
Expand Down
22 changes: 20 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,26 @@ jobs:
MAVEN_PASS: ${{ secrets.MAVEN_PASS }}
RELEASE: true
steps:
- name: Setup
uses: ./.github/workflows/setup.yml
- name: Checkout Repository
uses: actions/checkout@v4

- name: Setup Java
run: echo "JAVA_HOME=$JAVA_HOME_17_X64" >> "$GITHUB_ENV"

- name: Loom Cache
uses: actions/cache@v4
with:
path: "**/.gradle/loom-cache"
key: "${{ runner.os }}-gradle-${{ hashFiles('**/libs.versions.*', '**/*.gradle*', '**/gradle-wrapper.properties') }}"
restore-keys: "${{ runner.os }}-gradle-"

- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
with:
gradle-home-cache-cleanup: true

- name: Validate Gradle Wrapper Integrity
uses: gradle/wrapper-validation-action@v2

- name: Publish
# build task creates artifacts for capture and upload, then publish publishes to maven
Expand Down
28 changes: 0 additions & 28 deletions .github/workflows/setup.yml

This file was deleted.

19 changes: 17 additions & 2 deletions .github/workflows/snapshot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,23 @@ jobs:
MAVEN_USER: ${{ secrets.MAVEN_USER }}
MAVEN_PASS: ${{ secrets.MAVEN_PASS }}
steps:
- name: Setup
uses: ./.github/workflows/setup.yml
- name: Setup Java
run: echo "JAVA_HOME=$JAVA_HOME_17_X64" >> "$GITHUB_ENV"

- name: Loom Cache
uses: actions/cache@v4
with:
path: "**/.gradle/loom-cache"
key: "${{ runner.os }}-gradle-${{ hashFiles('**/libs.versions.*', '**/*.gradle*', '**/gradle-wrapper.properties') }}"
restore-keys: "${{ runner.os }}-gradle-"

- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
with:
gradle-home-cache-cleanup: true

- name: Validate Gradle Wrapper Integrity
uses: gradle/wrapper-validation-action@v2

- name: Publish
# build task creates artifacts for capture and upload, then publish publishes to maven
Expand Down

0 comments on commit 2f5e0e3

Please sign in to comment.