Why aliases in a non-interactive Bash shell do not work
The command shopt -s expand_aliases will allow alias expansion in non-interactive shells.
The command shopt -s expand_aliases will allow alias expansion in non-interactive shells.
You can stop this behaviour by setting nullglob: shopt -s nullglob From the linked page: nullglob is a Bash shell option which modifies [[glob]] expansion such that patterns that match no files expand to zero arguments, rather than to themselves. You can remove this setting with -u (unset, whereas s is for set): shopt -u … Read more