Skip to content

JJ/action-ktlint

 
 

Repository files navigation

action-ktlint status

GitHub Action for ktlint

This Action generates annotations from ktlint Report XML.

Usage

An example workflow(.github/workflows/ktlint.yml) to executing ktlint follows:

name: ktlint

on:
  pull_request:
    paths:
      - .github/workflows/ktlint.yml
      - 'src/**/*.kt'
      - '**.kts'

jobs:
  ktlint:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - run: brew install ktlint
      - name: run ktlint
        run: |
          ktlint --reporter=checkstyle,output=build/ktlint-report.xml
      - uses: yutailang0119/action-ktlint@v1.0.0
        with:
          xml_path: build/*.xml

Author

Yutaro Muta

References

License

action-ktlint is available under the MIT license. See the LICENSE file for more info.

About

GitHub Action for ktlint

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 94.9%
  • JavaScript 5.1%