How to use aliases defined in .bashrc in other scripts? May 28, 2023 by Tarik You need to do shopt -s expand_aliases in the script in addition to sourcing ~/.bashrc.