2019-01-14 13:55:36 +08:00
|
|
|
version: 2
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
working_directory: ~/code
|
|
|
|
docker:
|
2019-06-20 09:36:40 +08:00
|
|
|
- image: shadowsocks/android-ndk-go
|
2019-01-14 13:55:36 +08:00
|
|
|
environment:
|
|
|
|
JVM_OPTS: -Xmx3500m
|
|
|
|
GRADLE_OPTS: -Dorg.gradle.workers.max=1 -Dorg.gradle.daemon=false -Dkotlin.compiler.execution.strategy="in-process"
|
|
|
|
steps:
|
|
|
|
- checkout
|
|
|
|
- run: git submodule update --init --recursive
|
|
|
|
- restore_cache:
|
|
|
|
key: jars-{{ checksum "build.gradle" }}
|
2019-01-18 09:45:25 +08:00
|
|
|
- restore_cache:
|
2019-01-18 09:50:41 +08:00
|
|
|
key: go-{{ checksum "app/src/go/v2ray-plugin/go.sum" }}
|
2019-01-14 13:55:36 +08:00
|
|
|
- run:
|
|
|
|
name: Run Build and Tests
|
|
|
|
command: ./gradlew assembleDebug check
|
2019-01-18 09:45:25 +08:00
|
|
|
- save_cache:
|
|
|
|
paths:
|
|
|
|
- ~/go
|
2019-01-18 09:50:41 +08:00
|
|
|
key: go-{{ checksum "app/src/go/v2ray-plugin/go.sum" }}
|
2019-01-14 13:55:36 +08:00
|
|
|
- save_cache:
|
|
|
|
paths:
|
|
|
|
- ~/.gradle
|
|
|
|
- ~/.android/build-cache
|
|
|
|
key: jars-{{ checksum "build.gradle" }}
|
|
|
|
- store_artifacts:
|
|
|
|
path: app/build/outputs/apk
|
|
|
|
destination: apk
|
|
|
|
- store_artifacts:
|
|
|
|
path: app/build/reports
|
|
|
|
destination: reports
|