From 643366768f9a55e13fb8790ea7dd9ac050c55b7b Mon Sep 17 00:00:00 2001 From: rhysd Date: Fri, 22 Nov 2024 16:18:54 +0900 Subject: [PATCH] improve example to match any workflow files in `actionlint.yaml` (#481) --- config_test.go | 4 ++++ docs/config.md | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/config_test.go b/config_test.go index 89828d29a..7262ec878 100644 --- a/config_test.go +++ b/config_test.go @@ -165,6 +165,8 @@ paths: ignore: [vvv] .github/workflows/**/x.yaml: ignore: [www] + .github/workflows/**/*.{yml,yaml}: + ignore: [ttt] ` var cfg Config @@ -197,6 +199,8 @@ paths: {".github/workflows/a/b/x.yaml", "www", true}, {".github/workflows/a/b/c/x.yaml", "www", true}, {".github/workflows/a/b.yaml", "this is not ignored", false}, + {".github/workflows/a.yml", "xxx", false}, + {".github/workflows/a.yml", "ttt", true}, } for _, tc := range tests { diff --git a/docs/config.md b/docs/config.md index 35ca793e3..2a2fdc47f 100644 --- a/docs/config.md +++ b/docs/config.md @@ -32,7 +32,7 @@ config-variables: paths: # Glob pattern relative to the repository root for matching files. The path separator is always '/'. # This example configures any YAML file under the '.github/workflows/' directory. - .github/workflows/**/*.yaml: + .github/workflows/**/*.{yml,yaml}: # List of regular expressions to filter errors by the error messages. ignore: # Ignore the specific error from shellcheck