My own version #1387
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: PullRequest | |
on: | |
pull_request: | |
types: [opened, synchronize, reopened] | |
jobs: | |
Build: | |
name: Build | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ macOS-14 ] | |
java_version: [ 17 ] | |
steps: | |
- uses: actions/[email protected] | |
with: | |
submodules: true | |
fetch-depth: 0 # 0 indicates all history | |
- run: git fetch --all || echo "==> Accept any result" | |
- name: set up JDK | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'adopt' | |
java-version: ${{ matrix.java_version }} | |
- name: Install Android SDK | |
uses: hannesa2/action-android/[email protected] | |
- name: Build with Gradle | |
run: ./gradlew assembleDebug | |
# - name: Run instrumentation tests | |
# uses: hannesa2/action-android/[email protected] | |
# with: | |
# cmd: ./gradlew cAT -Pandroid.testInstrumentationRunnerArguments.notAnnotation=com.owncloud.android.testutil.annotation.FailsOnGithubAction --continue | |
# api: 28 | |
# tag: default | |
# abi: x86 | |
# - uses: actions/[email protected] | |
# if: ${{ always() }} | |
# with: | |
# name: owncloudApp-Espresso-test-report | |
# path: ${{ github.workspace }}/**/build/reports/androidTests/connected/* | |
# - name: Save logcat output | |
# uses: actions/[email protected] | |
# if: failure() | |
# with: | |
# name: ownCloud-logcat | |
# path: artifacts/logcat.log | |
Check: | |
name: Check | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ ubuntu-latest ] | |
java_version: [ 17 ] | |
steps: | |
- name: Checkout | |
uses: actions/[email protected] | |
with: | |
submodules: true | |
fetch-depth: 0 | |
- name: Install JDK | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'adopt' | |
java-version: ${{ matrix.java_version }} | |
- uses: gradle/wrapper-validation-action@v3 | |
- name: Install Android SDK | |
uses: hannesa2/action-android/[email protected] | |
- name: Code checks | |
run: ./gradlew lint | |
- name: Archive Lint report | |
uses: actions/[email protected] | |
if: ${{ always() }} | |
with: | |
name: ownCloud-Lint-report | |
path: lint-app-report.html |