#!/bin/bash # omarchy:summary=Control the Omarchy menu (toggle / summon / close / refresh) # omarchy:args=[toggle|summon|close|refresh|ping] [route] # omarchy:examples=omarchy menu | omarchy menu toggle system | omarchy menu summon style.theme | omarchy menu refresh # Thin wrapper around `omarchy-shell menu`. Keybinds and the bar icon # call omarchy-shell directly to skip the omarchy-CLI dispatch hop; # this exists so humans get `omarchy menu toggle X` etc. verb="${1-toggle}" route="${2-root}" case "$verb" in toggle | summon) exec omarchy-shell menu "$verb" "$route" ;; close | refresh | ping) exec omarchy-shell menu "$verb" ;; -h | --help | help) cat <, or close it if already open. Default verb. summon [route] Always open the menu (no close-if-visible toggle). close Close the menu if it is visible. refresh Re-parse the menu JSONC files. ping Health check. Route is an item id (e.g. setup.power) or alias (e.g. power). Defaults to "root", which opens the top-level menu. USAGE exit 0 ;; *) echo "omarchy-menu: unknown verb '$verb'. Try 'omarchy menu --help'." >&2 exit 2 ;; esac