Running 'blueutil --pair' as shell command

Hi,

I'm putting together a macro in which I execute a 'blueutil --pair' command as shell script. Unlike my current macro when I paste the command into a Terminal window, blueutil does not seem to wait until it sees the device. It looks like KM is quitting it before the device can pair. Is there a way to keep the process running in the background until blueutil finishes its job?

The Terminal version works fine, but I'd like to build a less intrusive version of my macro.

Thanks for your support!

It'll help if you post your macro -- instructions here.

An "Execute Shell Script" action generally waits for the shell script to complete before moving on. So...

  1. Have you set the action to run "asynchronously"?
  2. Is blueutil actually running? It isn't a macOS binary so will probably be installed outside of KM's default PATHs -- make sure you've either included the full path to the utility or have suitably updated your KM ENV_PATH variable
  3. Is blueutil erroring? The action suppresses errors by default -- try unchecking "Trim Results", checking "Include Errors", and setting the action to "Display results in a window" while troubleshooting
2 Likes

Thanks, @Nige_S! I made sure blueutil was running correctly, but I hadn't set the script to run asynchronously. It's working as expected now, thanks a lot!

Also thanks for the helpful link!