Update GitHub workflows

This commit is contained in:
Ash 2022-05-10 22:55:35 +08:00
parent 81fdcb498d
commit b292535ab6
2 changed files with 36 additions and 28 deletions

View File

@ -2,19 +2,23 @@ name: "Build Commit"
on: push
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v2
with:
distribution: temurin
java-version: 11
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v2
with:
distribution: temurin
java-version: 11
- uses: gradle/gradle-build-action@v2
- run: gradle assembleRelease
- uses: gradle/gradle-build-action@v2
- run: gradle assembleRelease
- uses: actions/upload-artifact@v3
with:
name: ${{ github.sha }}
path: app/build/outputs/apk/release/*.apk
- uses: actions/upload-artifact@v3
with:
name: github-${{ github.sha }}
path: app/build/outputs/apk/github/release/*.apk
- uses: actions/upload-artifact@v3
with:
name: fdroid-${{ github.sha }}
path: app/build/outputs/apk/fdroid/release/*.apk

View File

@ -2,19 +2,23 @@ name: "Build Pull Request"
on: pull_request
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v2
with:
distribution: temurin
java-version: 11
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v2
with:
distribution: temurin
java-version: 11
- uses: gradle/gradle-build-action@v2
- run: gradle assembleRelease
- uses: gradle/gradle-build-action@v2
- run: gradle assembleRelease
- uses: actions/upload-artifact@v3
with:
name: ${{ github.sha }}
path: app/build/outputs/apk/release/*.apk
- uses: actions/upload-artifact@v3
with:
name: github-${{ github.sha }}
path: app/build/outputs/apk/github/release/*.apk
- uses: actions/upload-artifact@v3
with:
name: fdroid-${{ github.sha }}
path: app/build/outputs/apk/fdroid/release/*.apk