react-native-vision-camera/.github/workflows/validate-android.yml
2023-09-21 19:16:13 +02:00

37 lines
1.0 KiB
YAML

name: Validate Android
on:
push:
branches:
- main
paths:
- '.github/workflows/validate-android.yml'
- 'package/android/**'
- 'package/.editorconfig'
pull_request:
paths:
- '.github/workflows/validate-android.yml'
- 'package/android/**'
- 'package/.editorconfig'
jobs:
KTLint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: |
curl -sSLO https://github.com/pinterest/ktlint/releases/download/1.0.0/ktlint && chmod a+x ktlint && sudo mv ktlint /usr/local/bin/
- name: run ktlint
working-directory: ./package/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: ./package/android/build/*.xml
continue-on-error: false
- uses: actions/upload-artifact@v3
with:
name: ktlint-report
path: ./package/android/build/*.xml