Question: the reason for bypassing auto-detection mode #2427
-
Hypothetical scenario:
as we are passing lintable args, the following logic got triggered and @ssbarnea could you advise on a reason for this logic, please. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Linting diffs does not work, mainly because a change make to one file can cause a breakage in a totally different file, one that is not touched. You are not the first, or the last to ask this question, sadly, the partial linting works only for playbook file type, so we did not bother to implement it. Regarding auto-detection of file type, you can customize the file patterns to match your needs. We also plan to remove the assumption that any passed file is a playbook but that counted as a major breaking change, as some people might be surprised to discover that ansible-lint passed without problems just because the yaml file was detected as not being owned by ansible (random yaml file for example). |
Beta Was this translation helpful? Give feedback.
Linting diffs does not work, mainly because a change make to one file can cause a breakage in a totally different file, one that is not touched. You are not the first, or the last to ask this question, sadly, the partial linting works only for playbook file type, so we did not bother to implement it.
Regarding auto-detection of file type, you can customize the file patterns to match your needs. We also plan to remove the assumption that any passed file is a playbook but that counted as a major breaking change, as some people might be surprised to discover that ansible-lint passed without problems just because the yaml file was detected as not being owned by ansible (random yaml file for e…