2020-01-26 06:10:01 +00:00
|
|
|
on:
|
2020-02-25 09:52:05 +00:00
|
|
|
push:
|
|
|
|
branches-ignore:
|
|
|
|
- master
|
2020-01-26 06:10:01 +00:00
|
|
|
|
2020-02-25 09:52:05 +00:00
|
|
|
name: Build debug
|
2020-01-26 06:10:01 +00:00
|
|
|
jobs:
|
2020-02-25 09:52:05 +00:00
|
|
|
generate-debug-build:
|
2020-01-26 06:10:01 +00:00
|
|
|
runs-on: ubuntu-latest
|
2020-02-25 09:52:05 +00:00
|
|
|
if: "!contains(github.event.head_commit.message, '[ci skip]')"
|
2020-01-26 06:10:01 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout repository
|
|
|
|
uses: actions/checkout@v1
|
|
|
|
|
|
|
|
- name: Decrypt secrets
|
|
|
|
run: release/signing-setup.sh "$ENCRYPT_KEY"
|
|
|
|
env:
|
|
|
|
ENCRYPT_KEY: ${{ secrets.ENCRYPT_KEY }}
|
|
|
|
|
2020-02-25 09:52:05 +00:00
|
|
|
- name: Copy CI gradle.properties
|
|
|
|
run: mkdir -p ~/.gradle ; cp .github/ci-gradle.properties ~/.gradle/gradle.properties
|
|
|
|
|
2020-01-26 06:10:01 +00:00
|
|
|
- uses: actions/cache@v1
|
|
|
|
with:
|
|
|
|
path: ~/.gradle/caches
|
|
|
|
key: gradle-${{ runner.os }}-${{ hashFiles('**/build.gradle') }}-${{ hashFiles('**/gradle/wrapper/gradle-wrapper.properties') }}-${{ hashFiles('**/dependencies.gradle') }}
|
|
|
|
|
|
|
|
- name: Download gradle dependencies
|
|
|
|
run: ./gradlew dependencies
|
|
|
|
|
2020-02-25 09:52:05 +00:00
|
|
|
- name: Build debug app
|
|
|
|
run: ./gradlew :app:assembleDebug
|
2020-01-26 06:10:01 +00:00
|
|
|
|
|
|
|
- name: Clean secrets
|
|
|
|
run: release/signing-cleanup.sh
|
|
|
|
|
2020-02-25 09:52:05 +00:00
|
|
|
- name: Send APK to Telegram
|
|
|
|
run: release/deploy-telegram.sh
|
2020-01-26 06:10:01 +00:00
|
|
|
env:
|
2020-02-25 09:52:05 +00:00
|
|
|
TG_TO: ${{ secrets.TELEGRAM_TO }}
|
|
|
|
TG_TOKEN: ${{ secrets.TELEGRAM_TOKEN }}
|
|
|
|
TG_FILE: ./app/build/outputs/apk/debug/app-debug.apk
|