Skip to content

Commit

Permalink
build: lint github workflows in pre-commit
Browse files Browse the repository at this point in the history
  • Loading branch information
guicamest committed Oct 19, 2023
1 parent 889e387 commit bc941dd
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ plugins {

include 'core', 'custom-ktlint-rules'

// See https://github.com/DanySK/gradle-pre-commit-git-hooks
gitHooks { extension ->
extension.with {
commitMsg { context ->
Expand All @@ -19,6 +20,9 @@ gitHooks { extension ->
context.with {
from(settingsDir.toPath().resolve(".hooks").resolve("pre-commit-ktlint-format").toFile())
tasks("clean", ["build"] as String[], false)
appendScript {
'docker run --rm -v $(pwd):/repo --workdir /repo rhysd/actionlint:1.6.26 -color'
}
}
}
createHooks(true)
Expand Down

0 comments on commit bc941dd

Please sign in to comment.