Skip to content

Commit

Permalink
👷 Update Gradle action arguments for APK assembly
Browse files Browse the repository at this point in the history
Replaced various "package" commands with corresponding "assemble"
commands across workflows for Fdroid, Playstore, and Github builds.

Should help or fix #675

Ref: https://gitlab.com/IzzyOnDroid/repo/-/issues/593
Signed-off-by: Leonardo Colman Lopes <[email protected]>
  • Loading branch information
LeoColman committed Aug 18, 2024
1 parent b97a845 commit 27afc15
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 16 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/build-debug.main.kts
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ workflow(
job(id = "build", runsOn = RunnerType.UbuntuLatest) {
uses(name = "Set up JDK", action = SetupJava(javaVersion = "17", distribution = SetupJava.Distribution.Adopt))
uses(action = Checkout())
uses(name = "Create Fdroid APK", action = GradleBuildAction(arguments = "packageFdroidDebugUniversalApk"))
uses(name = "Create Playstore APK", action = GradleBuildAction(arguments = "packagePlaystoreDebugUniversalApk"))
uses(name = "Create Github APK", action = GradleBuildAction(arguments = "packageGithubDebugUniversalApk"))
uses(name = "Create Fdroid APK", action = GradleBuildAction(arguments = "assembleFdroidDebug"))
uses(name = "Create Playstore APK", action = GradleBuildAction(arguments = "assemblePlaystoreDebug"))
uses(name = "Create Github APK", action = GradleBuildAction(arguments = "assembleGithubDebug"))
}
}
6 changes: 3 additions & 3 deletions .github/workflows/build-debug.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,14 @@ jobs:
name: 'Create Fdroid APK'
uses: 'gradle/gradle-build-action@v3'
with:
arguments: 'packageFdroidDebugUniversalApk'
arguments: 'assembleFdroidDebug'
- id: 'step-3'
name: 'Create Playstore APK'
uses: 'gradle/gradle-build-action@v3'
with:
arguments: 'packagePlaystoreDebugUniversalApk'
arguments: 'assemblePlaystoreDebug'
- id: 'step-4'
name: 'Create Github APK'
uses: 'gradle/gradle-build-action@v3'
with:
arguments: 'packageGithubDebugUniversalApk'
arguments: 'assembleGithubDebug'
6 changes: 3 additions & 3 deletions .github/workflows/build-release.main.kts
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ workflow(
uses(name = "Set up JDK", action = SetupJava(javaVersion = "17", distribution = SetupJava.Distribution.Adopt))
uses(action = Checkout())
uses(name = "reveal-secrets", action = GitSecretAction(gpgPrivateKey = expr { GPG_KEY }))
uses(name = "Create Fdroid APK", action = GradleBuildAction(arguments = "packageFdroidReleaseUniversalApk"))
uses(name = "Create Playstore APK", action = GradleBuildAction(arguments = "packagePlaystoreReleaseUniversalApk"))
uses(name = "Create Github APK", action = GradleBuildAction(arguments = "packageGithubReleaseUniversalApk"))
uses(name = "Create Fdroid APK", action = GradleBuildAction(arguments = "assembleFdroidRelease"))
uses(name = "Create Playstore APK", action = GradleBuildAction(arguments = "assemblePlaystoreRelease"))
uses(name = "Create Github APK", action = GradleBuildAction(arguments = "assembleGithubRelease"))
}
}
6 changes: 3 additions & 3 deletions .github/workflows/build-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,14 +43,14 @@ jobs:
name: 'Create Fdroid APK'
uses: 'gradle/gradle-build-action@v3'
with:
arguments: 'packageFdroidReleaseUniversalApk'
arguments: 'assembleFdroidRelease'
- id: 'step-4'
name: 'Create Playstore APK'
uses: 'gradle/gradle-build-action@v3'
with:
arguments: 'packagePlaystoreReleaseUniversalApk'
arguments: 'assemblePlaystoreRelease'
- id: 'step-5'
name: 'Create Github APK'
uses: 'gradle/gradle-build-action@v3'
with:
arguments: 'packageGithubReleaseUniversalApk'
arguments: 'assembleGithubRelease'
4 changes: 2 additions & 2 deletions .github/workflows/release.main.kts
Original file line number Diff line number Diff line change
Expand Up @@ -36,15 +36,15 @@ workflow(
uses(action = Checkout())
uses(name = "reveal-secrets", action = GitSecretAction(gpgPrivateKey = expr { GPG_KEY }))

uses(name = "Create APK", action = GradleBuildAction(arguments = "packageGithubReleaseUniversalApk"))
uses(name = "Create APK", action = GradleBuildAction(arguments = "assembleGithubRelease"))

uses(
name = "Create release", action = ActionGhRelease(
tagName = expr { GITHUB_REF_NAME },
name = "Version " + expr { GITHUB_REF_NAME },
draft = true,
files = listOf(
"app/build/outputs/apk_from_bundle/githubRelease/app-github-release-universal.apk",
"app/build/outputs/apk/github/release/app-github-release.apk",
"app/build/outputs/mapping/githubRelease/mapping.txt",
"app/build/outputs/mapping/githubRelease/configuration.txt",
"app/build/outputs/mapping/githubRelease/seeds.txt",
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
name: 'Create APK'
uses: 'gradle/gradle-build-action@v3'
with:
arguments: 'packageGithubReleaseUniversalApk'
arguments: 'assembleGithubRelease'
- id: 'step-4'
name: 'Create release'
uses: 'softprops/action-gh-release@v2'
Expand All @@ -52,7 +52,7 @@ jobs:
tag_name: '${{ github.GITHUB_REF_NAME }}'
draft: 'true'
files: |-
app/build/outputs/apk_from_bundle/githubRelease/app-github-release-universal.apk
app/build/outputs/apk/github/release/app-github-release.apk
app/build/outputs/mapping/githubRelease/mapping.txt
app/build/outputs/mapping/githubRelease/configuration.txt
app/build/outputs/mapping/githubRelease/seeds.txt
Expand Down

0 comments on commit 27afc15

Please sign in to comment.