diff --git a/CHANGELOG.md b/CHANGELOG.md index 1711cb54..9978dd90 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Overcommit Changelog +## master + +* Fix `YamlLint` pre-commit hook + ## 0.53.0 * Improve performance in `PhpCs` pre-commit hook diff --git a/config/default.yml b/config/default.yml index 74503e8e..b31e1f06 100644 --- a/config/default.yml +++ b/config/default.yml @@ -885,7 +885,7 @@ PreCommit: enabled: false description: 'Analyze with YAMLlint' required_executable: 'yamllint' - flags: ['--format=parsable'] + flags: ['--format=parsable', '--strict'] install_command: 'pip install yamllint' include: - '**/*.yaml' diff --git a/spec/overcommit/hook/pre_commit/yaml_lint_spec.rb b/spec/overcommit/hook/pre_commit/yaml_lint_spec.rb index 72ebc6e8..cb08f4e1 100644 --- a/spec/overcommit/hook/pre_commit/yaml_lint_spec.rb +++ b/spec/overcommit/hook/pre_commit/yaml_lint_spec.rb @@ -19,7 +19,7 @@ end before do - subject.stub(:execute).with(%w[yamllint --format=parsable], args: applicable_files). + subject.stub(:execute).with(%w[yamllint --format=parsable --strict], args: applicable_files). and_return(result) end