File tree 1 file changed +6
-4
lines changed
1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -31,15 +31,17 @@ jobs:
31
31
- name : Find changed rules files
32
32
id : set-changed-files
33
33
run : |
34
- # if we skip changed-files because we're not in a pull-request,
35
- # then we consider all the rules contained in the repo
34
+ # Find any changed file located under the /rules folder that matches the naming convention <ruleset>_rules.yaml.
35
+ # See https://github.com/falcosecurity/rules/blob/main/README.md#naming-convention for details.
36
+ # Additionally, if we skip changed-files because we're not in a pull request,
37
+ # then we consider all the rules contained in the repository.
36
38
all_files="${{ steps.changed-files.outputs.all }}"
37
39
values=""
38
40
if [ -z "$all_files" ]; then
39
- values=$(ls rules/*.yaml)
41
+ values=$(ls rules/*_rules .yaml)
40
42
else
41
43
for changed_file in $all_files; do
42
- if [[ "${changed_file}" =~ ^rules/.* ]]; then
44
+ if [[ "${changed_file}" =~ ^rules/[^/]*_rules\.yaml$ ]]; then
43
45
values=${values}${changed_file}$'\n'
44
46
fi
45
47
done
You can’t perform that action at this time.
0 commit comments