Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid duplicates when injecting extra ansible lookup paths #1348

Merged
merged 1 commit into from Feb 14, 2021
Merged

Avoid duplicates when injecting extra ansible lookup paths #1348

merged 1 commit into from Feb 14, 2021

Conversation

joren485
Copy link
Contributor

Description

Because the default paths are added, without checking if they are already present, they might be added twice:

$ ANSIBLE_ROLES_PATH=roles ansible-lint
Added ANSIBLE_ROLES_PATH=roles:roles

This PR fixes this behaviour by only adding the default paths if they are not already present.

@ssbarnea ssbarnea changed the title Add collection and roles directories only if they have not been added by the env vars Avoid duplicates when injecting extra ansible lookup paths Feb 14, 2021
@ssbarnea ssbarnea merged commit e99b2cc into ansible:master Feb 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants