Fix "no matches for wildcard" error in env-setup.fish script. (#58345)

See https://github.com/ansible/ansible/pull/58345#discussion_r297288979
This commit is contained in:
Elijah Lynn 2019-06-27 15:15:13 -07:00 committed by Sam Doran
parent ec1287ca7e
commit 19c6448459

View file

@ -65,9 +65,10 @@ set -gx ANSIBLE_LIBRARY $ANSIBLE_HOME/library
# Do the work in a fuction
function gen_egg_info
if test -e $PREFIX_PYTHONPATH/ansible*.egg-info
rm -rf "$PREFIX_PYTHONPATH/ansible*.egg-info"
# Cannot use `test` on wildcards.
# @see https://github.com/fish-shell/fish-shell/issues/5960
if count $PREFIX_PYTHONPATH/ansible*.egg-info > /dev/null
rm -rf $PREFIX_PYTHONPATH/ansible*.egg-info
end
if [ $QUIET ]