2023-12-02 07:58:43 -07:00
|
|
|
name: Check Android
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
paths:
|
|
|
|
- '.github/workflows/check-android.yml'
|
|
|
|
- 'android/**'
|
|
|
|
pull_request:
|
|
|
|
paths:
|
|
|
|
- '.github/workflows/check-android.yml'
|
|
|
|
- 'android/**'
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
Kotlin-Lint:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- run: |
|
2023-12-07 00:47:40 -07:00
|
|
|
curl -sSLO https://github.com/pinterest/ktlint/releases/download/1.0.1/ktlint && chmod a+x ktlint && sudo mv ktlint /usr/local/bin/
|
2023-12-02 07:58:43 -07:00
|
|
|
- name: run ktlint
|
|
|
|
working-directory: ./android/
|
|
|
|
run: |
|
|
|
|
ktlint --reporter=checkstyle,output=build/ktlint-report.xml --relative --editorconfig=./.editorconfig
|
|
|
|
continue-on-error: true
|
|
|
|
- uses: yutailang0119/action-ktlint@v3
|
|
|
|
with:
|
|
|
|
report-path: ./android/build/*.xml
|
|
|
|
continue-on-error: false
|
|
|
|
- uses: actions/upload-artifact@v3
|
|
|
|
with:
|
|
|
|
name: ktlint-report
|
|
|
|
path: ./android/build/*.xml
|