Skip to content

Commit 0892c6f

Browse files
authored
Fix gradle_snapshot.yml - need to checkout/gradle at push too (#8059)
* Fix gradle_snapshot.yml - need to checkout/gradle at push too * Fix gradle_release.yml also
1 parent d15f4a3 commit 0892c6f

File tree

2 files changed

+35
-5
lines changed

2 files changed

+35
-5
lines changed

.github/workflows/gradle_release.yml

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
CI_BUILD_NUMBER: ${{ github.run_number }}
2222
steps:
2323
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
24-
- name: Set up JDK 11
24+
- name: Set up JDK 25
2525
uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654 # v5.2.0
2626
with:
2727
distribution: 'zulu'
@@ -34,8 +34,6 @@ jobs:
3434
restore-keys: ${{ runner.os }}-gradle-${{ secrets.CACHE_VERSION }}
3535
- name: Grant execute permission for gradlew
3636
run: chmod +x gradlew
37-
- name: Grant execute permission for push
38-
run: chmod +x push_javadoc.sh
3937
- name: Extract version tag
4038
run: echo "BUILD_TAG=${GITHUB_REF:10}" >> $GITHUB_ENV
4139
- name: Run Validity Tests Upfront
@@ -51,6 +49,24 @@ jobs:
5149
permissions:
5250
contents: write
5351
steps:
52+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
53+
- name: Set up JDK 25
54+
uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654 # v5.2.0
55+
with:
56+
distribution: 'zulu'
57+
java-version: '25'
58+
- name: Cache Gradle packages
59+
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
60+
with:
61+
path: ~/.gradle/caches
62+
key: ${{ runner.os }}-gradle-${{ secrets.CACHE_VERSION }}-${{ hashFiles('**/*.gradle') }}
63+
restore-keys: ${{ runner.os }}-gradle-${{ secrets.CACHE_VERSION }}
64+
- name: Grant execute permission for gradlew
65+
run: chmod +x gradlew
66+
- name: Grant execute permission for push
67+
run: chmod +x push_javadoc.sh
68+
- name: Extract version tag
69+
run: echo "BUILD_TAG=${GITHUB_REF:10}" >> $GITHUB_ENV
5470
- name: Publish release
5571
run: ./gradlew -PreleaseMode=full publishAndReleaseToMavenCentral --no-configuration-cache --no-daemon --no-parallel --stacktrace
5672
env:

.github/workflows/gradle_snapshot.yml

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,6 @@ jobs:
3333
restore-keys: ${{ runner.os }}-gradle-${{ secrets.CACHE_VERSION }}
3434
- name: Grant execute permission for gradlew
3535
run: chmod +x gradlew
36-
- name: Grant execute permission for push
37-
run: chmod +x push_javadoc.sh
3836
- name: Run Validity Tests Upfront
3937
run: ./gradlew test --tests "io.reactivex.rxjava4.validators.*" --stacktrace --no-daemon
4038
- name: Build RxJava
@@ -46,6 +44,22 @@ jobs:
4644
env:
4745
CI_BUILD_NUMBER: ${{ github.run_number }}
4846
steps:
47+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
48+
- name: Set up JDK 25
49+
uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654 # v5.2.0
50+
with:
51+
distribution: 'zulu'
52+
java-version: '25'
53+
- name: Cache Gradle packages
54+
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
55+
with:
56+
path: ~/.gradle/caches
57+
key: ${{ runner.os }}-gradle-${{ secrets.CACHE_VERSION }}-${{ hashFiles('**/*.gradle') }}
58+
restore-keys: ${{ runner.os }}-gradle-${{ secrets.CACHE_VERSION }}
59+
- name: Grant execute permission for gradlew
60+
run: chmod +x gradlew
61+
- name: Grant execute permission for push
62+
run: chmod +x push_javadoc.sh
4963
- name: Upload Snapshot
5064
run: ./gradlew -PreleaseMode=branch publishAllPublicationsToMavenCentralRepository --no-daemon --no-parallel --stacktrace
5165
env:

0 commit comments

Comments
 (0)