Update Docs #12
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name : AndroidBuild | |
on: | |
pull_request: | |
branches: [master,develop] | |
push: | |
branches: [master,develop] | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: | |
ubuntu-latest | |
permissions: | |
contents: read | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4.1.0 | |
- name : Set Up Java | |
uses: actions/setup-java@v4.2.1 | |
with: | |
java-version: '17' | |
distribution: 'adopt' | |
- name: Make gradlew executable | |
run: chmod +x ./gradlew | |
- name: Get local.properties from secrets | |
run: echo "${{secrets.LOCAL_PROPERTIES }}" > $GITHUB_WORKSPACE/local.properties | |
- name: Run ktlintFormat on the codebase | |
run: ./gradlew ktlintFormat | |
- name: Run ktlintCheck on the codebase | |
run: ./gradlew ktlintCheck | |
- name: Build With Gradle | |
run: ./gradlew build | |
- name: Run Unit Tests | |
run: ./gradlew clean test | |
- name: Run debug Build | |
run: ./gradlew assembleDebug | |
- name: Upload a Build Artifact | |
uses: actions/upload-artifact@v4.3.3 | |
with: | |
name : CalorieBytezDebug.apk | |
path : app/build/outputs/apk/debug/app-debug.apk | |