Skip to content

Commit 4dc3959

Browse files
committed
fix: add **/*.patch.yaml as the suggested exclude
1 parent 5a07280 commit 4dc3959

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ k8s-validate [--kubernetes-version X.X.X] [--exclude glob-pattern] files
1818

1919
Add a section similar to this to your .pre-commit-hooks.yaml:
2020
- repo: https://github.com/Agilicus/pre-commit-hook-k8svalidate.git
21-
rev: v0.0.5
21+
rev: v0.0.6
2222
hooks:
2323
- id: k8svalidate
24-
args: [--exclude, "*.patch.yaml"]
24+
args: [--exclude, "**/*.patch.yaml"]
2525
files: .yaml$

pre-commit-hooks/k8svalidate

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ def main():
9494
except utils.SchemaNotFoundError:
9595
result = "Skipped [Unknown Schema]"
9696
except jsonschema.exceptions.ValidationError as e:
97-
result = f"FAIL [{str(e)}]"
97+
result = f"FAIL [{e.args[0]}]"
9898
valid = False
9999
else:
100100
result = "Skipped [Not Kubernetes YAML]"

0 commit comments

Comments
 (0)