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