Skip to content

Commit

Permalink
feat: Add pre-commit hook support
Browse files Browse the repository at this point in the history
Add pre-commit hook support for flipt validate. This allows users to add
a pre-commit hook that calls validates flipt feature flag configuration
as part of GitOps workflows.
  • Loading branch information
jalaziz committed Nov 27, 2023
1 parent 38569b5 commit 1b0a080
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions .pre-commit-hooks.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
- id: flipt-validate
name: flipt validate
description: Fast linters runner for Go. Runs on all files in the repo. Use this hook if you use pre-commit in CI.
entry: flipt validate
language: golang
types: [yaml]
pass_filenames: false
files: |
(?x)^(
.*/features\.yaml|
.*/features\.yml|
.*?/.*\.features.yaml|
.*?/.*\.features.yml
)$

0 comments on commit 1b0a080

Please sign in to comment.