ansible/ansible — pull request #5950 by willthames (2014-02-11 01:30:28+00:00)
Title: Combine module path settings from ANSIBLE_LIBRARY and config

##### Issue Type:

Feature Pull Request

##### Ansible Version:

Based on
ansible 1.5 (devel 4688be33d4) last updated 2014/02/11 09:49:34 (GMT +1000)

##### Environment:

N/A

##### Summary:

Currently if you use e.g. hacking/env-setup, that will set your ANSIBLE_LIBRARY to be the library
directory below the ansible installation. Any library path in the ANSIBLE_CONFIG configuration
file is completely ignored.

Should you wish to use user specific modules, there
are various options none of which are ideal:
* Update ANSIBLE_LIBRARY after running env-setup
* Make a symlink in the playbook directory called library back to the user specific library
* Use -M flag each time you run ansible-playbook

This change basically merges the results of ANSIBLE_LIBRARY, the library config value in
ANSIBLE_CONFIG and the default module path (DIST_MODULE_PATH, typically /usr/share/ansible).

##### Steps To Reproduce:

See https://gist.github.com/willthames/8912987

##### Expected Results:

I can use ANSIBLE_LIBRARY from hacking/env_setup in addition to library in ANSIBLE_CONFIG file.

##### Actual Results:

The library value in the configuration file is ignored if ANSIBLE_LIBRARY is set.