This preset displays buttons for triggering Alfred workflows in the touch bar when the Alfred search bar is activated with a keyboard shortcut (e.g. cmd-space). Could be useful if you have a large number of Alfred workflows and have trouble remembering them.
Here's what it looks like (workflows not included):
It works by:
- Using BTT to setup a keyboard shortcut that simultaneously activates the Alfred search bar (via applescript) and a touch bar group
- Setting up an external applescript trigger for the workflows in Alfred and creating buttons for triggering those workflows in the touch bar group
- Using BTT to create an escape key that also closes touch bar groups
It works this way because there's no way to detect the Alfred search bar itself. This does cause some problems:
- This wouldn't work for you if you don't want the escape key to close groups. But you could workaround this by creating an escape key that closes groups specifically for the Alfred workflows group.
- Left clicking anywhere outside the Alfred search bar when it is open closes the search bar, but not the touch bar group. BTT can detect left clicks but there is no option to trigger actions using left clicks. @Andreas_Hegenberg would it be possible to add that option? Given that option, I would use a conditional activation group to close the Alfred workflows group on left click.
On the whole though I find that it works quite smoothly.
- Requires Alfred 3 with Powerpack: https://www.alfredapp.com
- BTT preset: https://share.folivora.ai/sharedPreset/918335e2-5596-4e0d-a1cb-388e568f8cd0
- Example Alfred workflow: BTT-Alfred integration example.zip (1.4 KB)