Skip to content

Ansible-lint check all files in repo, not only files in commit #1121

Answered by ingtarius
ingtarius asked this question in Q&A
Discussion options

You must be logged in to vote

I solve this by using this entry in pre-commit

entry: bash -c "ansible-lint $(git diff --name-only --cached | egrep '.(yml|yaml)')"

This commit change policy, so i dont know best solution: https://github.com/ansible-community/ansible-lint/pull/932/files

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by ingtarius
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #1121 on December 14, 2020 08:14.