Skip to content

Master build

Master build #59

Workflow file for this run

name: Master build
on:
push:
branches: [ "master" ]
schedule:
- cron: '0 1 * * *'
jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/[email protected]
- name: Restore Cache
uses: actions/cache@v2
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: Execute Lint
run: |
chmod +x ./gradlew
./gradlew lintDebug
- name: Upload Lint Reports
if: ${{ always() }}
uses: actions/upload-artifact@v2
with:
name: lint-report
path: '**/build/reports/lint-results-*'
unit_tests:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/[email protected]
- name: Restore Cache
uses: actions/cache@v2
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: Execute Tests
run: |
chmod +x ./gradlew
./gradlew testDebugUnitTest --continue
- name: Upload Test Reports
if: ${{ always() }}
uses: actions/upload-artifact@v2
with:
name: test-reports
path: '**/build/reports/tests/'
assemble:
needs: [lint, unit_tests]
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/[email protected]
- name: Restore Cache
uses: actions/cache@v2
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: Assemble
run: |
chmod +x ./gradlew
./gradlew assembleDebug
- name: Upload APK
uses: actions/upload-artifact@v2
with:
name: apk
path: app/build/outputs/apk/debug/**.apk