From 867ef141cd84c24cec0e1da10c72bd29a66c75f4 Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Sun, 22 Dec 2024 22:50:16 +0100 Subject: [PATCH 01/19] Setup spotless and pre-commit --- .github/workflows/test.yml | 3 ++- .pre-commit-config.yaml | 13 +++++++++++++ README.md | 9 +++++++++ build.gradle | 19 +++++++++++++++++++ 4 files changed, 43 insertions(+), 1 deletion(-) create mode 100644 .pre-commit-config.yaml diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 3b3e8f5f5..5fd2bd833 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -32,7 +32,8 @@ jobs: echo BACKTRACE_SUBMISSION_URL=\"${{ secrets.BACKTRACE_SUBMISSION_URL }}\" >> ./local.properties echo BACKTRACE_CORONER_URL=\"${{ secrets.BACKTRACE_CORONER_URL }}\" >> ./local.properties echo BACKTRACE_CORONER_TOKEN=\"${{ secrets.BACKTRACE_CORONER_TOKEN }}\" >> ./local.properties - + - name: Check Code Style + run: ./gradlew spotlessCheck - name: Build and check run: ./gradlew assembleDebug assembleDebugAndroidTest build check diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 000000000..9735a7dd3 --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,13 @@ +repos: + - repo: local + hooks: + - id: spotless-apply + name: Spotless Apply + entry: ./gradlew spotlessApply + language: system + stages: [pre-commit] + - id: spotless-check + name: Spotless Check + entry: ./gradlew spotlessCheck + language: system + stages: [pre-commit] diff --git a/README.md b/README.md index d3096d31c..f7163af3f 100644 --- a/README.md +++ b/README.md @@ -70,3 +70,12 @@ backtraceClient.metrics.enable() ## Documentation For more information about the Android SDK, including installation, usage, and configuration options, see the [Android Integration guide](https://docs.saucelabs.com/error-reporting/platform-integrations/android/setup/) in the Sauce Labs documentation. + +## Contribution + +TODO: improve + +``` +pip install pre-commit +pre-commit install +``` diff --git a/build.gradle b/build.gradle index 2ee9fb94b..c9fb4fefd 100644 --- a/build.gradle +++ b/build.gradle @@ -13,6 +13,25 @@ buildscript { } } +plugins { + id 'com.diffplug.spotless' version '6.25.0' apply false +} + +subprojects { + apply plugin: 'com.diffplug.spotless' + spotless { + java { + googleJavaFormat('1.25.2') // Specify the version of Google Java Format + indentWithTabs(1) + indentWithSpaces(2) + target fileTree('.') { + include '**/*.java' + exclude '**/build/**', '**/build-*/**', '**/.cxx/**' + } + } + } +} + allprojects { repositories { google() From 370186d5d46b18607c461f758a11d5498dad9d9e Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Sun, 22 Dec 2024 22:57:10 +0100 Subject: [PATCH 02/19] Fix pre-commit-config --- .pre-commit-config.yaml | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 9735a7dd3..f2350addb 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,13 +1,22 @@ repos: - repo: local hooks: - - id: spotless-apply - name: Spotless Apply - entry: ./gradlew spotlessApply - language: system - stages: [pre-commit] - - id: spotless-check - name: Spotless Check - entry: ./gradlew spotlessCheck + - id: test-hook + name: test-hook + entry: echo 'test' language: system stages: [pre-commit] + pass_filenames: false + +# - id: spotless-apply +# name: Spotless Apply +# entry: ./gradlew spotlessApply +# language: system +# stages: [pre-commit] +# pass_filenames: false +# - id: spotless-check +# name: Spotless Check +# entry: ./gradlew spotlessCheck +# language: system +# stages: [pre-commit] +# pass_filenames: false From 67b9cd6003ac92685e050457d1e0335f0c81038b Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Mon, 23 Dec 2024 12:38:14 +0100 Subject: [PATCH 03/19] Improve docs --- .pre-commit-config.yaml | 1 + CONTRIBUTING.md | 10 ++++++++-- README.md | 9 --------- 3 files changed, 9 insertions(+), 11 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index f2350addb..d70dde568 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -8,6 +8,7 @@ repos: stages: [pre-commit] pass_filenames: false +# TODO: before merge - remove above and uncomment below # - id: spotless-apply # name: Spotless Apply # entry: ./gradlew spotlessApply diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index bf7251903..9570d7242 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -9,13 +9,19 @@ Thank you for considering contributing to Backtrace Android SDK library. Here ar git clone https://github.com/backtrace-labs/backtrace-android.git ``` -2. **Create a Branch** +2. **Install pre-commit +```bash +pip install pre-commit +pre-commit install +``` + +3. **Create a Branch** - It's good practice to create a new branch for each feature or bugfix, if you have jira ticket put ticket number as branch prefix: ```bash git checkout -b jira-ticket/your-feature-name ``` -3. **Update submodules** +4. **Update submodules** ```bash git submodule update --recursive --remote git submodule update --init --recursive diff --git a/README.md b/README.md index f7163af3f..d3096d31c 100644 --- a/README.md +++ b/README.md @@ -70,12 +70,3 @@ backtraceClient.metrics.enable() ## Documentation For more information about the Android SDK, including installation, usage, and configuration options, see the [Android Integration guide](https://docs.saucelabs.com/error-reporting/platform-integrations/android/setup/) in the Sauce Labs documentation. - -## Contribution - -TODO: improve - -``` -pip install pre-commit -pre-commit install -``` From bb223bc3acac1584394b5f6d709189d5032fdc43 Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Mon, 23 Dec 2024 13:11:18 +0100 Subject: [PATCH 04/19] Fix typo --- CONTRIBUTING.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 9570d7242..7373338c6 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -9,7 +9,7 @@ Thank you for considering contributing to Backtrace Android SDK library. Here ar git clone https://github.com/backtrace-labs/backtrace-android.git ``` -2. **Install pre-commit +2. **Install pre-commit** ```bash pip install pre-commit pre-commit install From 48eb471f2f453a344e6459cda0fda7f1885cc0bf Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Mon, 23 Dec 2024 13:14:49 +0100 Subject: [PATCH 05/19] Reformat file --- CONTRIBUTING.md | 35 +++++++++++++++++------------------ 1 file changed, 17 insertions(+), 18 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 7373338c6..82ad0ce6d 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -4,29 +4,28 @@ Thank you for considering contributing to Backtrace Android SDK library. Here ar ### Getting Started 1. **Clone the Repository** - - Clone the repository to your local machine using: - ```bash - git clone https://github.com/backtrace-labs/backtrace-android.git - ``` - + Clone the repository to your local machine using: + ```bash + git clone https://github.com/backtrace-labs/backtrace-android.git + ``` 2. **Install pre-commit** -```bash -pip install pre-commit -pre-commit install -``` + ```bash + pip install pre-commit + pre-commit install + ``` 3. **Create a Branch** - - It's good practice to create a new branch for each feature or bugfix, if you have jira ticket put ticket number as branch prefix: - ```bash - git checkout -b jira-ticket/your-feature-name - ``` + It's good practice to create a new branch for each feature or bugfix, if you have jira ticket put ticket number as branch prefix: + ```bash + git checkout -b jira-ticket/your-feature-name + ``` 4. **Update submodules** -```bash -git submodule update --recursive --remote -git submodule update --init --recursive -``` - + ```bash + git submodule update --recursive --remote + git submodule update --init --recursive + ``` + ### Coding Guidelines 1. **Code Formatting** From 99989acf6e5743653786e472337218bec88f4326 Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Mon, 23 Dec 2024 13:16:55 +0100 Subject: [PATCH 06/19] Reformat --- CONTRIBUTING.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 82ad0ce6d..d652946d8 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -3,19 +3,18 @@ Thank you for considering contributing to Backtrace Android SDK library. Here ar ### Getting Started -1. **Clone the Repository** - Clone the repository to your local machine using: +1. **Clone the repository** to your local machine using: ```bash git clone https://github.com/backtrace-labs/backtrace-android.git ``` + 2. **Install pre-commit** ```bash pip install pre-commit pre-commit install ``` -3. **Create a Branch** - It's good practice to create a new branch for each feature or bugfix, if you have jira ticket put ticket number as branch prefix: +3. **Create a branch** - it's good practice to create a new branch for each feature or bugfix, if you have jira ticket put ticket number as branch prefix: ```bash git checkout -b jira-ticket/your-feature-name ``` From 7ac11f24b23fea09af4cf819dc717107c624b9ff Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Mon, 23 Dec 2024 13:18:44 +0100 Subject: [PATCH 07/19] Fix doc --- CONTRIBUTING.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index d652946d8..af8dcb0e5 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -3,7 +3,7 @@ Thank you for considering contributing to Backtrace Android SDK library. Here ar ### Getting Started -1. **Clone the repository** to your local machine using: +1. **Clone the repository** ```bash git clone https://github.com/backtrace-labs/backtrace-android.git ``` From ff017e522db7b026dc22a1222276beeff3fb9caa Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Sun, 5 Oct 2025 20:48:53 +0200 Subject: [PATCH 08/19] Bump spotless plugin version --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 272d944d8..afbf55ebd 100644 --- a/build.gradle +++ b/build.gradle @@ -14,7 +14,7 @@ buildscript { } plugins { - id 'com.diffplug.spotless' version '6.25.0' apply false + id 'com.diffplug.spotless' version '7.21.0' apply false } subprojects { From 1c1cee0bc23ebdff4c01ac692a17faa6d22e8d6c Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Sun, 5 Oct 2025 20:49:24 +0200 Subject: [PATCH 09/19] Tmp update pre-commit --- .pre-commit-config.yaml | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index d70dde568..d48b79ded 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -9,15 +9,15 @@ repos: pass_filenames: false # TODO: before merge - remove above and uncomment below -# - id: spotless-apply -# name: Spotless Apply -# entry: ./gradlew spotlessApply -# language: system -# stages: [pre-commit] -# pass_filenames: false -# - id: spotless-check -# name: Spotless Check -# entry: ./gradlew spotlessCheck -# language: system -# stages: [pre-commit] -# pass_filenames: false + - id: spotless-apply + name: Spotless Apply + entry: ./gradlew spotlessApply + language: system + stages: [pre-commit] + pass_filenames: false + - id: spotless-check + name: Spotless Check + entry: ./gradlew spotlessCheck + language: system + stages: [pre-commit] + pass_filenames: false From 25a036ac5a73d23e2765659a8b980e86c85b22ea Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Sun, 5 Oct 2025 21:00:04 +0200 Subject: [PATCH 10/19] Fix version google java format and plugin --- build.gradle | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build.gradle b/build.gradle index afbf55ebd..9cc6ff525 100644 --- a/build.gradle +++ b/build.gradle @@ -14,14 +14,14 @@ buildscript { } plugins { - id 'com.diffplug.spotless' version '7.21.0' apply false + id 'com.diffplug.spotless' version '7.2.1' apply false } subprojects { apply plugin: 'com.diffplug.spotless' spotless { java { - googleJavaFormat('1.25.2') // Specify the version of Google Java Format + googleJavaFormat('1.29.0') // Specify the version of Google Java Format indentWithTabs(1) indentWithSpaces(2) target fileTree('.') { From d42aeea4df016e31611129310828a7b30df8839f Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Mon, 6 Oct 2025 22:52:55 +0200 Subject: [PATCH 11/19] Update config --- build.gradle | 28 +++++++++++++++++++++++++--- 1 file changed, 25 insertions(+), 3 deletions(-) diff --git a/build.gradle b/build.gradle index 9cc6ff525..6ac2d0b81 100644 --- a/build.gradle +++ b/build.gradle @@ -21,14 +21,36 @@ subprojects { apply plugin: 'com.diffplug.spotless' spotless { java { - googleJavaFormat('1.29.0') // Specify the version of Google Java Format - indentWithTabs(1) - indentWithSpaces(2) + googleJavaFormat('1.29.0').aosp() // Specify the version of Google Java Format + removeUnusedImports() + trimTrailingWhitespace() + endWithNewline() target fileTree('.') { include '**/*.java' exclude '**/build/**', '**/build-*/**', '**/.cxx/**' } } + format 'json', { + target '**/*.json' + leadingTabsToSpaces(2) + trimTrailingWhitespace() + endWithNewline() + targetExclude('**/build/**', '**/.cxx/**', '**/generated/**') + } + + format 'gradle', { + target '**/*.gradle' + leadingTabsToSpaces(4) + trimTrailingWhitespace() + endWithNewline() + } + + + format 'misc', { + target '*.md', '.gitignore' + trimTrailingWhitespace() + endWithNewline() + } } } From 1ca804a7a2c9113dced579e019cd2e6ae91a25f4 Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Wed, 8 Oct 2025 21:56:24 +0200 Subject: [PATCH 12/19] Bump spotless plugin --- build.gradle | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build.gradle b/build.gradle index 6ac2d0b81..2dd00228b 100644 --- a/build.gradle +++ b/build.gradle @@ -14,14 +14,14 @@ buildscript { } plugins { - id 'com.diffplug.spotless' version '7.2.1' apply false + id 'com.diffplug.spotless' version '8.0.0' apply false } subprojects { apply plugin: 'com.diffplug.spotless' spotless { java { - googleJavaFormat('1.29.0').aosp() // Specify the version of Google Java Format + palantirJavaFormat() removeUnusedImports() trimTrailingWhitespace() endWithNewline() From 80c3a705be005cfe03b2a03e8ea026cd0ac15d31 Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Sun, 12 Oct 2025 10:12:43 +0200 Subject: [PATCH 13/19] Improve CONTRIBUTING.md - add information about spotless --- .pre-commit-config.yaml | 33 ++++++++++++++++----------------- CONTRIBUTING.md | 37 +++++++++++++++++++++++++++++++------ 2 files changed, 47 insertions(+), 23 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index d48b79ded..adcdd78d9 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,23 +1,22 @@ repos: - repo: local hooks: - - id: test-hook - name: test-hook - entry: echo 'test' - language: system - stages: [pre-commit] - pass_filenames: false - -# TODO: before merge - remove above and uncomment below - - id: spotless-apply - name: Spotless Apply - entry: ./gradlew spotlessApply - language: system - stages: [pre-commit] - pass_filenames: false - - id: spotless-check - name: Spotless Check - entry: ./gradlew spotlessCheck + - id: start-hook + name: start-hook + entry: echo 'Start pre-commit' language: system stages: [pre-commit] pass_filenames: false +## TODO: before merge - remove above and uncomment below +# - id: spotless-apply +# name: Spotless Apply +# entry: ./gradlew spotlessApply +# language: system +# stages: [pre-commit] +# pass_filenames: false +# - id: spotless-check +# name: Spotless Check +# entry: ./gradlew spotlessCheck +# language: system +# stages: [pre-commit] +# pass_filenames: false diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index af8dcb0e5..f3733e386 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,7 +1,7 @@ # Contributing -Thank you for considering contributing to Backtrace Android SDK library. Here are some guidelines to help you get started: +Thank you for your interest in contributing to the Backtrace Android SDK. Please review the following guidelines to help you get started. -### Getting Started +## Getting Started 1. **Clone the repository** ```bash @@ -25,7 +25,7 @@ Thank you for considering contributing to Backtrace Android SDK library. Here ar git submodule update --init --recursive ``` -### Coding Guidelines +## Coding Guidelines 1. **Code Formatting** - Make sure that your code is properly formatted using the default Android Studio formatter. @@ -38,7 +38,7 @@ Thank you for considering contributing to Backtrace Android SDK library. Here ar 3. **Write Tests** - Ensure that you write tests for the new functionality or changes made. This helps maintain the integrity of the project. -### Commit and Push +## Commit and Push 1. **Commit Your Changes** - Write clear and concise commit messages. Follow the convention of using the imperative mood in the subject line. @@ -52,7 +52,7 @@ Thank you for considering contributing to Backtrace Android SDK library. Here ar git push origin jira-ticket/your-feature-name ``` -### Create a Pull Request +## Create a Pull Request 1. **Submit a Pull Request** - Go to the repository on GitHub and click on the `New Pull Request` button. @@ -61,8 +61,33 @@ Thank you for considering contributing to Backtrace Android SDK library. Here ar 2. **Review Process** - One of the project maintainers will review your pull request. Please be responsive to any comments or suggestions made. -### Additional Notes +## Additional Notes - Ensure that your code follows the existing code style and structure. - Keep your branch up to date with the latest changes from the `master` branch to avoid merge conflicts. + +## Code Formatting + +This project uses **[Spotless](https://github.com/diffplug/spotless)** (a code formatting plugin) integrated with **[pre-commit](https://pre-commit.com/)** to ensure consistent code style and automatic formatting before each commit. + +### Setup Instructions + +1. Run Spotless check +This verifies that your code meets the project’s formatting standards. + ```bash + ./gradlew spotlessCheck + ``` + +2. (Optional) Automatically reformat code +If formatting issues are found, you can automatically fix them with: + ```bash + ./gradlew spotlessApply + ``` + +**Notes** +- The pre-commit hook ensures code formatting is validated automatically before commits are created. +- You can manually trigger all pre-commit checks at any time with: + ```bash + pre-commit run --all-files + ``` From 2f93e88f0867e1f55d6293dfb51c1c8045db501e Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Wed, 15 Oct 2025 18:05:32 +0200 Subject: [PATCH 14/19] Improve json format rules --- build.gradle | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/build.gradle b/build.gradle index 2dd00228b..bb8af0531 100644 --- a/build.gradle +++ b/build.gradle @@ -30,11 +30,9 @@ subprojects { exclude '**/build/**', '**/build-*/**', '**/.cxx/**' } } - format 'json', { + json { target '**/*.json' - leadingTabsToSpaces(2) - trimTrailingWhitespace() - endWithNewline() + simple() targetExclude('**/build/**', '**/.cxx/**', '**/generated/**') } From 7392e72849e1e9b7f4d5a114579c4287f5f03954 Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Wed, 15 Oct 2025 21:43:48 +0200 Subject: [PATCH 15/19] Improve spotless exclude rules --- build.gradle | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/build.gradle b/build.gradle index bb8af0531..26a6f28d6 100644 --- a/build.gradle +++ b/build.gradle @@ -17,6 +17,15 @@ plugins { id 'com.diffplug.spotless' version '8.0.0' apply false } +def spotlessExcludes = [ + '**/cpp/**', + '**/jniLibs/**', + '**/build/**', + '**/build-*/**', + '**/.cxx/**', + '**/generated/**' +] + subprojects { apply plugin: 'com.diffplug.spotless' spotless { @@ -27,17 +36,18 @@ subprojects { endWithNewline() target fileTree('.') { include '**/*.java' - exclude '**/build/**', '**/build-*/**', '**/.cxx/**' } + targetExclude spotlessExcludes } json { target '**/*.json' simple() - targetExclude('**/build/**', '**/.cxx/**', '**/generated/**') + targetExclude spotlessExcludes } format 'gradle', { target '**/*.gradle' + targetExclude spotlessExcludes leadingTabsToSpaces(4) trimTrailingWhitespace() endWithNewline() @@ -46,6 +56,7 @@ subprojects { format 'misc', { target '*.md', '.gitignore' + targetExclude spotlessExcludes trimTrailingWhitespace() endWithNewline() } From e0a3646a8cd33093fa8b13104b5065557057f736 Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Wed, 15 Oct 2025 22:24:03 +0200 Subject: [PATCH 16/19] Fix rules --- build.gradle | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/build.gradle b/build.gradle index 26a6f28d6..0f0477b0f 100644 --- a/build.gradle +++ b/build.gradle @@ -18,6 +18,10 @@ plugins { } def spotlessExcludes = [ + '.github/**', + '.gradle/**', + '.idea/**', + 'build/**', '**/cpp/**', '**/jniLibs/**', '**/build/**', @@ -30,19 +34,17 @@ subprojects { apply plugin: 'com.diffplug.spotless' spotless { java { + target '**/*.java' + targetExclude spotlessExcludes palantirJavaFormat() removeUnusedImports() trimTrailingWhitespace() endWithNewline() - target fileTree('.') { - include '**/*.java' - } - targetExclude spotlessExcludes } json { target '**/*.json' - simple() targetExclude spotlessExcludes + simple() } format 'gradle', { From 6e5a499bdbe31e266d3d51433495bd0c8c4d4d6f Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Wed, 15 Oct 2025 22:42:31 +0200 Subject: [PATCH 17/19] Reorder spotless check --- .github/workflows/test.yml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index cf1616dd3..8deb680e6 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,14 +12,6 @@ jobs: runs-on: ubuntu-latest steps: - - name: Checkout submodules - uses: actions/checkout@v4 - with: - fetch-depth: 2 - submodules: recursive - token: ${{ secrets.ACCESS_TOKEN }} - persist-credentials: false - - name: set up JDK 17 uses: actions/setup-java@v4 with: @@ -27,6 +19,9 @@ jobs: distribution: "adopt" cache: gradle + - name: Check Code Style + run: ./gradlew spotlessCheck + - name: Write to local.properties run: | echo BACKTRACE_SUBMISSION_URL=\"${{ secrets.BACKTRACE_SUBMISSION_URL }}\" >> ./local.properties @@ -36,8 +31,13 @@ jobs: - name: Accept Android SDK licences run: yes | "${ANDROID_HOME}/cmdline-tools/latest/bin/sdkmanager" --licenses - - name: Check Code Style - run: ./gradlew spotlessCheck + - name: Checkout submodules + uses: actions/checkout@v4 + with: + fetch-depth: 2 + submodules: recursive + token: ${{ secrets.ACCESS_TOKEN }} + persist-credentials: false - name: Build and check run: ./gradlew assembleDebug assembleDebugAndroidTest build check From 1ccfbf05503dbbfe51f49c528bbe84b78e480b61 Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Wed, 15 Oct 2025 22:46:11 +0200 Subject: [PATCH 18/19] Reorder build --- .github/workflows/test.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 8deb680e6..688fb3c5c 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,6 +12,9 @@ jobs: runs-on: ubuntu-latest steps: + - name: Accept Android SDK licences + run: yes | "${ANDROID_HOME}/cmdline-tools/latest/bin/sdkmanager" --licenses + - name: set up JDK 17 uses: actions/setup-java@v4 with: @@ -28,8 +31,6 @@ jobs: echo BACKTRACE_CORONER_URL=\"${{ secrets.BACKTRACE_CORONER_URL }}\" >> ./local.properties echo BACKTRACE_CORONER_TOKEN=\"${{ secrets.BACKTRACE_CORONER_TOKEN }}\" >> ./local.properties - - name: Accept Android SDK licences - run: yes | "${ANDROID_HOME}/cmdline-tools/latest/bin/sdkmanager" --licenses - name: Checkout submodules uses: actions/checkout@v4 From 848cf593316b9923ca297dd86522ea98e00395df Mon Sep 17 00:00:00 2001 From: Bartosz Litwiniuk <> Date: Wed, 15 Oct 2025 22:48:22 +0200 Subject: [PATCH 19/19] Revert --- .github/workflows/test.yml | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 688fb3c5c..cf1616dd3 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,8 +12,13 @@ jobs: runs-on: ubuntu-latest steps: - - name: Accept Android SDK licences - run: yes | "${ANDROID_HOME}/cmdline-tools/latest/bin/sdkmanager" --licenses + - name: Checkout submodules + uses: actions/checkout@v4 + with: + fetch-depth: 2 + submodules: recursive + token: ${{ secrets.ACCESS_TOKEN }} + persist-credentials: false - name: set up JDK 17 uses: actions/setup-java@v4 @@ -22,23 +27,17 @@ jobs: distribution: "adopt" cache: gradle - - name: Check Code Style - run: ./gradlew spotlessCheck - - name: Write to local.properties run: | echo BACKTRACE_SUBMISSION_URL=\"${{ secrets.BACKTRACE_SUBMISSION_URL }}\" >> ./local.properties echo BACKTRACE_CORONER_URL=\"${{ secrets.BACKTRACE_CORONER_URL }}\" >> ./local.properties echo BACKTRACE_CORONER_TOKEN=\"${{ secrets.BACKTRACE_CORONER_TOKEN }}\" >> ./local.properties + - name: Accept Android SDK licences + run: yes | "${ANDROID_HOME}/cmdline-tools/latest/bin/sdkmanager" --licenses - - name: Checkout submodules - uses: actions/checkout@v4 - with: - fetch-depth: 2 - submodules: recursive - token: ${{ secrets.ACCESS_TOKEN }} - persist-credentials: false + - name: Check Code Style + run: ./gradlew spotlessCheck - name: Build and check run: ./gradlew assembleDebug assembleDebugAndroidTest build check