0
0
mirror of https://github.com/TrianguloY/UrlChecker.git synced 2024-09-19 03:42:15 +02:00

migrate gradle actions to latest version

This commit is contained in:
TrianguloY 2024-08-21 17:15:25 +02:00
parent 187641dda3
commit 977572fcc1
3 changed files with 9 additions and 25 deletions

View File

@ -34,16 +34,11 @@ jobs:
java-version: '17'
distribution: 'temurin'
- name: Set gradlew as executable
# for some reason the gradle-build-action doesn't do this automatically
run: chmod +x ./gradlew
- name: Setup gradle
uses: gradle/actions/setup-gradle@v4
- name: Build & assemble with gradle
uses: gradle/gradle-build-action@v3
with:
arguments: >
build
assemble${{ env.VARIANT }}
- name: Build & assemble
run: ./gradlew build assemble${{ env.VARIANT }}
- name: Zip ${{ env.VARIANT }} apk as ${{ env.ZIP }}
# just remove the password here if you want to build the apk yourself instead of sponsoring me and getting it as a benefit :(

View File

@ -34,28 +34,17 @@ jobs:
java-version: '17'
distribution: 'temurin'
- name: Validate Gradle wrapper
uses: gradle/wrapper-validation-action@v3
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v4
- name: Change wrapper permissions
# for some reason the gradle-build-action doesn't do this automatically
run: chmod +x ./gradlew
- name: Build & test with Gradle
uses: gradle/gradle-build-action@v3
with:
arguments: >
build
test
- name: Build & test
run: ./gradlew build test
# the following steps will only run for PRs
- name: "[PR] Generate apk"
if: ${{ github.event_name == 'pull_request_target' }}
uses: gradle/gradle-build-action@v3
with:
arguments: >
assemble${{ env.VARIANT }}
run: ./gradlew assemble${{ env.VARIANT }}
- name: "[PR] Upload apk as artifact"
id: artifact-upload-step

0
gradlew vendored Normal file → Executable file
View File