Some folks struggle when they find out that the default $PATH from their Terminal.app environment is NOT replicated in Keyboard Maestro.
There's a simple way to work around this, and that is to add a variable named
ENV_PATH to Keyboard Maestro and give it the same path you can find in your Terminal by using the command
I have automated this process in the appended macro.
If using macOS Ventura or later you'll need to change “Preferences” to “Settings” in the Select or Show a Menu Item action in the macro.
Download: Make ENV_PATH Variable in Keyboard Maestro Using the Terminal v1.00.kmmacros (12 KB)
Here's a pretty painless way to to compare your macOS Terminal and Keyboard Maestro $PATH strings.
- KM creates it's own environment for shell scripts it is often at variance with the Terminal environment.
- The user is responsible for managing these differences.
- Hopefully this tool will help with that.
Download: Compare Terminal & Keyboard Maestro $PATH Strings v1.00.kmmacros (14 KB)
- Macros are always disabled when imported into the Keyboard Maestro Editor.
- The user must ensure the macro is enabled.
- The user must also ensure the macro's parent macro-group is enabled.
- macOS 10.14.6
- Keyboard Maestro v10.2