The solution is to source the file dependencies you need inside the automator script.

Example if you added all of your scripts to ~/.zshrc

source ~/.zshrc
deploy

You can debug things easier by doing which deploy to check to see if that script is accessible.


Automator runs in its own environment and does not read your shell rc files. The PATH is limited to /usr/bin:/bin:/usr/sbin:/sbin. None of the environment is exported for further use. You could define the function in Run Shell Script and run it like this:

 deploy () {
 cd ~/Path/To/My/Project;
 build ...;
 rsync ...;
 }

 deploy

Though this is somewhat limited.