Commit graph

15 commits

Author SHA1 Message Date
Sam Doran
4de516d35f Do not set ANSIBLE_LIBRARY in env-setup.fish (#63688)
Setting this env var was removed from env-setup back in 2014. Not sure why it is in this setup script and it interferes with the defult search path
2019-10-18 10:56:19 -04:00
Elijah Lynn
19c6448459 Fix "no matches for wildcard" error in env-setup.fish script. (#58345)
See https://github.com/ansible/ansible/pull/58345#discussion_r297288979
2019-06-27 18:15:11 -04:00
Matt Clay
f3d1f9544b
Make ansible-test available in the bin directory. (#45876) 2018-09-19 17:58:55 -07:00
Sam Doran
aa19563388 Improve fish environment setup (#26151)
* Add test runner to PATH

* Add Python3 support

* Updating env-setup.fish to use more portable '-exec' rather than '-delete'

* Create gen_egg_info function

Move code into a function similar to env-setup.

Silence all output when run with -q
2017-08-01 09:41:21 -04:00
Sam Doran
cf8639ff62 Fish hacking setup fix (#18084)
* Remove old egg-info files before creating new ones

Currently, setup.py generates egg files then they are deleted. This change
fixes this behavior and matches that in env-setup.

* Do not try to move ansible*egg-info to lib/

setup.py creates the ansible.egg-info in lib/ so this step is unnecessary. Matches env-setup behavior.

* Better test for number of arguments in argv

This prevents an erronous error message from being thrown since set -q returns an error code with the number of variables not defined, resulting in a non-zero exit if no arguments are passed.

Indent case statement within switch statement.
2016-10-24 10:35:00 -07:00
André Pinto
fa4011c6c3 Do not corrupt $MANPATH when it's not present (#16300)
Fixes #16299
2016-06-15 11:41:14 -04:00
Brett Inman
1f89a46b52 Make -q flag totally quiet for env-setup.fish
The first echo and setup.py steps are not quiet and result in output that is annoying if your Fish is configured to source the file.
2016-04-27 11:34:51 -07:00
Luke Rohde
cba4642d8d Use find ... -delete instead of non-portable globbing 2015-09-02 17:05:16 -04:00
Luke Rohde
647e48f776 Delete all compiled python files when running hacking/env-setup 2015-09-02 14:49:02 -04:00
Brian Coca
88443d6dcf Merge pull request #7306 from abadger/feature/egg-info
Feature/egg info
2014-12-15 16:26:37 -05:00
Michael Salmon
e827ec702e Fix issue #8578. Setting envvar in ""'s ensures the PYTHONPATH is set to
include the lib/ directory.

Before - PYTHONPATH is empty.. ansible fails to run

    $ source hacking/env-setup.fish
    Appending PYTHONPATH

    Setting up Ansible to run out of checkout...

    PATH=/Volumes/opt/src/ansible/bin /usr/local/share/python3 /usr/local/bin
    /usr/bin /bin /usr/sbin /sbin /usr/local/bin /opt/X11/bin /usr/bin /sbin
    /usr/local/bin /Users/ms/bin/
    PYTHONPATH=
    ANSIBLE_LIBRARY=/Volumes/opt/src/ansible/library
    ...

    Traceback (most recent call last):
      File "/Volumes/opt/src/ansible/bin/ansible", line 25, in <module>
          from ansible.runner import Runner
          ImportError: No module named ansible.runner

After change - it's set.. ansible runs.

    source hacking/env-setup.fish
    Appending PYTHONPATH

    Setting up Ansible to run out of checkout...

    PATH=/Volumes/opt/src/ansible/bin /usr/local/share/python3 /usr/local/bin
    /usr/bin /bin /usr/sbin /sbin /usr/local/bin /opt/X11/bin /usr/bin /sbin
    /usr/local/bin /Users/ms/bin/
    PYTHONPATH=/Volumes/opt/src/ansible/lib:
    ANSIBLE_LIBRARY=/Volumes/opt/src/ansible/library
    ....

    $ ansible
    Usage: ansible <host-pattern> [options]
2014-08-12 12:09:20 -07:00
Toshio Kuratomi
6a6060ac55 Teach env-setup how to create egg-info for ansible so that pkg_resources works 2014-05-06 11:19:41 -07:00
Jharrod LaFon
996f87d898 Fixed usage comment to fish syntax for sourcing a file 2013-08-14 15:52:37 -06:00
Jharrod LaFon
d0fe447fd1 Fixed incorrectly set PYTHONPATH 2013-08-14 10:46:58 -06:00
Jharrod LaFon
dbfcd78790 Added an env-setup file for Fish 2013-08-13 15:14:01 -06:00