ci: add Gradle CI workflow with APK artifact upload#2
Conversation
Agent-Logs-Url: https://github.com/kimocoder/Hijacker/sessions/bddaa3f3-059a-47af-9b13-91630c14a8cb Co-authored-by: kimocoder <4252297+kimocoder@users.noreply.github.com>
Agent-Logs-Url: https://github.com/kimocoder/Hijacker/sessions/bddaa3f3-059a-47af-9b13-91630c14a8cb Co-authored-by: kimocoder <4252297+kimocoder@users.noreply.github.com>
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
There was a problem hiding this comment.
Pull request overview
Adds an Android-focused GitHub Actions workflow to build a debug APK on pushes and pull requests and publish it as a downloadable artifact.
Changes:
- Introduces a new
Gradle CIworkflow triggered onpushandpull_request. - Sets up JDK 17 + Gradle caching, runs
./gradlew assembleDebug, and uploads the debug APK output as an artifact.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| build: | ||
| runs-on: ubuntu-latest | ||
| permissions: | ||
| contents: read |
There was a problem hiding this comment.
The job-level permissions restrict GITHUB_TOKEN to contents: read, but actions/upload-artifact typically requires actions: write to create artifacts. As written, the upload step is likely to fail with a permissions error; add actions: write (or remove the restrictive permissions block) so artifact upload works while still keeping least-privilege.
| contents: read | |
| contents: read | |
| actions: write |
| distribution: 'temurin' | ||
|
|
||
| - name: Setup Gradle | ||
| uses: gradle/actions/setup-gradle@v4 |
There was a problem hiding this comment.
gradle/actions/setup-gradle is referenced as @v4 here, but the existing workflow pins this action to a specific commit (see .github/workflows/gradle-publish.yml), which reduces supply-chain risk. Please pin gradle/actions/setup-gradle to a commit SHA (optionally with a comment noting the version) for consistency with the repository’s workflow conventions.
| uses: gradle/actions/setup-gradle@v4 | |
| uses: gradle/actions/setup-gradle@017a9effdb900e5b5b2fddfb590a105619dca3c3 # v4 |
Adds a GitHub Actions CI workflow that builds the Android debug APK on every push and pull request and uploads it as a downloadable artifact.
Changes
.github/workflows/android-ci.yml— new "Gradle CI" workflow:pushandpull_requestgradle-publish.yml; compatible with AGP 9.x)gradle/actions/setup-gradle@v4./gradlew assembleDebugapp/build/outputs/apk/debug/*.apkas artifactapk-debug; errors if no APK producedGITHUB_TOKENscoped tocontents: readOriginal prompt
This pull request was created from Copilot chat.