|
|
|
|
|
by anderskaseorg
1696 days ago
|
|
In a script, there will almost never be any aliases defined, because noninteractive shells don’t load ~/.bashrc. $ sh -c "which ls; command -v ls"
/bin/ls
/bin/ls
If the script is #!bash rather than #!sh, it’s not even possible to define an alias. $ bash -c "alias ls='ls --color=auto'; which ls; command -v ls"
/bin/ls
/bin/ls
|
|