2021-02-23 06:29:59 -07:00
|
|
|
name: Validate Android
|
2021-02-23 05:59:42 -07:00
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
2021-02-23 06:00:32 -07:00
|
|
|
- main
|
2021-02-23 05:59:42 -07:00
|
|
|
paths:
|
2021-02-23 06:29:59 -07:00
|
|
|
- '.github/workflows/validate-android.yml'
|
2023-09-01 17:04:36 -06:00
|
|
|
- 'package/android/**'
|
2024-01-29 03:23:42 -07:00
|
|
|
- 'package/android/.editorconfig'
|
2021-02-23 05:59:42 -07:00
|
|
|
pull_request:
|
|
|
|
paths:
|
2021-02-23 06:29:59 -07:00
|
|
|
- '.github/workflows/validate-android.yml'
|
2023-09-01 17:04:36 -06:00
|
|
|
- 'package/android/**'
|
2024-01-29 03:23:42 -07:00
|
|
|
- 'package/android/.editorconfig'
|
2021-02-23 05:59:42 -07:00
|
|
|
|
|
|
|
jobs:
|
2023-09-21 11:16:13 -06:00
|
|
|
KTLint:
|
2023-09-21 11:06:33 -06:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
2024-01-29 03:23:42 -07:00
|
|
|
- name: Download ktlint
|
2023-09-21 11:06:33 -06:00
|
|
|
working-directory: ./package/android/
|
|
|
|
run: |
|
2024-01-29 03:23:42 -07:00
|
|
|
curl -sSLO https://github.com/pinterest/ktlint/releases/download/1.1.1/ktlint
|
|
|
|
chmod a+x ktlint
|
|
|
|
- name: Run ktlint
|
|
|
|
working-directory: ./package/android/
|
|
|
|
run: |
|
|
|
|
./ktlint --reporter=checkstyle,output=build/ktlint-report.xml --relative --editorconfig=./.editorconfig
|
2023-09-21 11:06:33 -06:00
|
|
|
continue-on-error: true
|
|
|
|
- uses: yutailang0119/action-ktlint@v3
|
|
|
|
with:
|
|
|
|
report-path: ./package/android/build/*.xml
|
|
|
|
continue-on-error: false
|
2024-01-31 09:26:03 -07:00
|
|
|
- uses: actions/upload-artifact@v4
|
2023-09-21 11:06:33 -06:00
|
|
|
with:
|
|
|
|
name: ktlint-report
|
|
|
|
path: ./package/android/build/*.xml
|