chore: Separate download and run step in ktlint CI (#2448)

* Separate download and run step in ktlint

* fix: Upgrade ktlint to 1.1.1
This commit is contained in:
Marc Rousavy 2024-01-29 11:23:42 +01:00 committed by GitHub
parent c911d25727
commit 61f6b47cd8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -7,24 +7,27 @@ on:
paths:
- '.github/workflows/validate-android.yml'
- 'package/android/**'
- 'package/.editorconfig'
- 'package/android/.editorconfig'
pull_request:
paths:
- '.github/workflows/validate-android.yml'
- 'package/android/**'
- 'package/.editorconfig'
- 'package/android/.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
- name: Download ktlint
working-directory: ./package/android/
run: |
ktlint --reporter=checkstyle,output=build/ktlint-report.xml --relative --editorconfig=./.editorconfig
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
continue-on-error: true
- uses: yutailang0119/action-ktlint@v3
with: