From 2d6bd33475f3067e0fd7f6a446ca6657fa337ba4 Mon Sep 17 00:00:00 2001 From: alefvanoon <53198048+alefvanoon@users.noreply.github.com> Date: Mon, 7 Feb 2022 17:33:06 +0000 Subject: [PATCH 1/4] Add CI https://github.com/libre-tube/LibreTube/issues/13 --- .github/workflows/ci.yml | 52 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 000000000..863ff379b --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,52 @@ +name: CI + +on: + workflow_dispatch: + pull_request: + branches: + - master + paths-ignore: + - 'README*.md' + - 'fastlane/**' + - 'assets/**' + - '.github/**/*.md' + push: + branches: + - master + paths-ignore: + - 'README*.md' + - 'fastlane/**' + - 'assets/**' + - '.github/**/*.md' + +jobs: + build-and-test-jvm: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: gradle/wrapper-validation-action@v1 + + - name: create and checkout branch + # push events already checked out the branch + if: github.event_name == 'pull_request' + run: git checkout -B ${{ github.head_ref }} + + - name: set up JDK 11 + uses: actions/setup-java@v2 + with: + java-version: 11 + distribution: "temurin" + cache: 'gradle' + + - name: Make gradlew executable + run: chmod +x ./gradlew + + + - name: Build debug APK and run jvm tests + run: ./gradlew assembleDebug + + - name: Upload APK + uses: actions/upload-artifact@v2 + with: + name: app + path: app/build/outputs/apk/debug/*.apk From bb896eb2fefac8888d52d6375220b4cfc066de24 Mon Sep 17 00:00:00 2001 From: alefvanoon <53198048+alefvanoon@users.noreply.github.com> Date: Mon, 7 Feb 2022 17:44:23 +0000 Subject: [PATCH 2/4] Change job name --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 863ff379b..5463c5572 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -20,7 +20,7 @@ on: - '.github/**/*.md' jobs: - build-and-test-jvm: + debug-builds: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 From 7c4e40e49f4634ba9463d5acb16f7c5e57ccee2e Mon Sep 17 00:00:00 2001 From: alefvanoon <53198048+alefvanoon@users.noreply.github.com> Date: Tue, 8 Feb 2022 13:31:35 +0000 Subject: [PATCH 3/4] Remove checkout branch from CI --- .github/workflows/ci.yml | 9 --------- 1 file changed, 9 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5463c5572..f9a6ed51e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -3,16 +3,12 @@ name: CI on: workflow_dispatch: pull_request: - branches: - - master paths-ignore: - 'README*.md' - 'fastlane/**' - 'assets/**' - '.github/**/*.md' push: - branches: - - master paths-ignore: - 'README*.md' - 'fastlane/**' @@ -26,11 +22,6 @@ jobs: - uses: actions/checkout@v2 - uses: gradle/wrapper-validation-action@v1 - - name: create and checkout branch - # push events already checked out the branch - if: github.event_name == 'pull_request' - run: git checkout -B ${{ github.head_ref }} - - name: set up JDK 11 uses: actions/setup-java@v2 with: From 3d4e165d0a61bbbf3606ff9af47569e7344e4bed Mon Sep 17 00:00:00 2001 From: alefvanoon <53198048+alefvanoon@users.noreply.github.com> Date: Tue, 8 Feb 2022 14:28:41 +0000 Subject: [PATCH 4/4] Remove Make gradlew executable --- .github/workflows/ci.yml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f9a6ed51e..85877e49c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,10 +29,6 @@ jobs: distribution: "temurin" cache: 'gradle' - - name: Make gradlew executable - run: chmod +x ./gradlew - - - name: Build debug APK and run jvm tests run: ./gradlew assembleDebug