I try to execute the following shell command via applescript for fetching the cordova version:
do shell script "cd /usr/local/bin/; cordova -v;"
If I use the same command in terminal it works, in AppleScript I get the error:
sh: cordova: command not found
How can I solve the problem?
After a couple of tests, if figured out the solution:
do shell script "export PATH=$PATH:/usr/local/bin; cordova -v;"