From bc941ddf9c041ed1f27c5da5cd133ecaf9922a13 Mon Sep 17 00:00:00 2001 From: guicamest Date: Thu, 19 Oct 2023 11:45:21 +0200 Subject: [PATCH] build: lint github workflows in pre-commit --- settings.gradle | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/settings.gradle b/settings.gradle index 6f89a34..3c3a0a0 100644 --- a/settings.gradle +++ b/settings.gradle @@ -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 -> @@ -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)