version: 2 jobs: test: docker: - image: registry.gitlab.com/fdroid/ci-images-client:latest steps: - checkout - restore_cache: key: gradle-{{ checksum "build.gradle" }}-{{ checksum ".circleci/config.yml" }} - run: export GRADLE_USER_HOME=$PWD/.gradle - run: echo y | sdkmanager "platforms;android-$(sed -n 's,.*compileSdkVersion\s*\([0-9][0-9]*\).*,\1,p' build.gradle)" > /dev/null - run: ./gradlew lintStandardDebug - save_cache: paths: - .gradle/caches - .gradle/wrapper key: gradle-{{ checksum "build.gradle" }}-{{ checksum ".circleci/config.yml" }} - store_artifacts: path: build/outputs/apk/standard destination: apk build: docker: - image: registry.gitlab.com/fdroid/ci-images-client:latest steps: - checkout - restore_cache: key: android - run: export GRADLE_USER_HOME=$PWD/.gradle - run: echo y | sdkmanager "platforms;android-$(sed -n 's,.*compileSdkVersion\s*\([0-9][0-9]*\).*,\1,p' build.gradle)" > /dev/null - run: ./gradlew assembleStandard - save_cache: paths: - ~/.android key: android - store_artifacts: path: build/outputs/apk/standard destination: apk workflows: version: 2 build_test: jobs: - build