This will allow you to create alias
es that take a command,
and execute it in a target
directory when that is available
Usage:
-
download
execute-in.sh
and place it in your home dir -
make this file executable
chmod +x execute-in.sh
-
create an alias
alias `command`="~/execute-in.sh `target` `command`"
alias yarn="~/execute-in.sh app/javascript yarn"