Browse the docs

frontApp

The bundle identifier of the app in front, such as com.apple.finder.

Details #

Use it anywhere a {{ }} expression is allowed, as {{frontApp}} in a step's text or as frontApp inside a longer expression. It also works as a call, frontApp(). It is the front app's bundle identifier, the stable form to compare against. For the name people see, use frontAppName. If nothing is in front, the result is an empty string.

A run variable with the same name wins. If a step stores something in a variable called frontApp, {{frontApp}} reads that variable, not the live value. Name your own variables something else.

Parameters #

Write it as {{frontApp}} in any text field. A variable of the same name wins.

Examples #

frontApp == "com.apple.finder"
→ true
Sample variableValue
frontAppcom.apple.finder
Show the front app id
When
  1. Press ⌃⌥J
Do
  1. Show “Front app: {{frontApp}}”
Open in Switchboard to try it

See also #