mirror of
https://github.com/ansible/ansible-documentation.git
synced 2026-03-26 13:18:58 +07:00
Honor --quiet parameter properly in fish shell (#77180)
* The `^` stderr redirection is deprecated * Setting `-q` for `setup.py` in `gen_egg_info` is redundant
This commit is contained in:
3
changelogs/fragments/77180-fix-fish-env-setup-script.yml
Normal file
3
changelogs/fragments/77180-fix-fish-env-setup-script.yml
Normal file
@@ -0,0 +1,3 @@
|
||||
bugfixes:
|
||||
- hacking - fix incorrect usage of deprecated fish-shell redirection operators
|
||||
that failed to honor ``--quiet`` flag when sourced (https://github.com/ansible/ansible/pull/77180).
|
||||
@@ -80,20 +80,15 @@ function gen_egg_info
|
||||
rm -rf $PREFIX_PYTHONPATH/ansible*.egg-info
|
||||
end
|
||||
|
||||
if [ $QUIET ]
|
||||
set options '-q'
|
||||
end
|
||||
|
||||
eval $PYTHON_BIN setup.py $options egg_info
|
||||
|
||||
eval $PYTHON_BIN setup.py egg_info
|
||||
end
|
||||
|
||||
|
||||
pushd $ANSIBLE_HOME
|
||||
|
||||
if [ $QUIET ]
|
||||
gen_egg_info ^ /dev/null
|
||||
find . -type f -name "*.pyc" -exec rm -f '{}' ';' ^ /dev/null
|
||||
gen_egg_info &> /dev/null
|
||||
find . -type f -name "*.pyc" -exec rm -f '{}' ';' &> /dev/null
|
||||
else
|
||||
gen_egg_info
|
||||
find . -type f -name "*.pyc" -exec rm -f '{}' ';'
|
||||
|
||||
Reference in New Issue
Block a user