Skip to content

Commit a48496e

Browse files
authored
pre-commit: stop specifying types in hook (#274)
* pre-commit: stop specifying types in hook This PR updates the pre-commit hook to not force `yaml` files. `yamlfmt` is designed to accept all files in a working directory and filter through what files are accepted based on configuration (i.e. it's perfectly valid for users to configure `yamlfmt` to accept files that wouldn't match pre-commit's `yaml` type). * also update hook version cause I'm gonna bump for this
1 parent 9b3f475 commit a48496e

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

.pre-commit-hooks.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,3 @@
1717
description: This hook uses github.com/google/yamlfmt to format yaml files. Requires Go >1.18 to be installed.
1818
entry: yamlfmt
1919
language: golang
20-
types: [yaml]

docs/pre-commit.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Starting in v0.7.1, `yamlfmt` can be used as a hook for the popular [pre-commit]
44

55
```yaml
66
- repo: https://github.com/google/yamlfmt
7-
rev: v0.17.0
7+
rev: v0.18.0
88
hooks:
99
- id: yamlfmt
1010
```
@@ -17,7 +17,7 @@ If you would prefer to manage your `yamlfmt` installation yourself, you can have
1717

1818
```yaml
1919
- repo: https://github.com/google/yamlfmt
20-
rev: v0.17.0
20+
rev: v0.18.0
2121
hooks:
2222
- id: yamlfmt
2323
language: system

0 commit comments

Comments
 (0)