Skip to content

Commit

Permalink
feat: add github action for ktlint
Browse files Browse the repository at this point in the history
  • Loading branch information
teccheck committed Dec 12, 2024
1 parent 1aac46a commit 909e8ba
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .github/worklfows/checks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Checks

on:
pull_request:
types: [ opened, synchronize, reopened ]
push:
branches: [ master ]

jobs:
wrapper-validation:
name: "Gradle Wrapper Validation"
runs-on: ubuntu-latest
timeout-minutes: 45
steps:
- uses: actions/checkout@v4
- uses: gradle/wrapper-validation-action@v2

ktlint:
name: "ktlint"
runs-on: ubuntu-latest
timeout-minutes: 45
steps:
- uses: actions/checkout@v4
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17'
- name: "Install ktlint"
run: |
curl -sSLO https://github.com/pinterest/ktlint/releases/download/1.5.0/ktlint && chmod a+x ktlint && sudo mv ktlint /usr/local/bin/
- name: "Run ktlint"
run: sh .ci/lint.sh ktlint

0 comments on commit 909e8ba

Please sign in to comment.