Shell commands
Megamenu stores the command text in your menu data. A longer script is an ordinary file you save yourself. The menu entry only needs the name or the one-liner.
Add one from the menu
Section titled “Add one from the menu”- Press
Ctrl+N, or + Item. - Choose Command.
- Title is the label in the menu, for example
Restic Backup. - Command is what runs. That can be a program already on
PATH, such asrestic-backup, or a single line such asnotify-send "Backup finished". - Working directory is optional. Set it when the command has to start inside a project, for example
pnpm devin~/Work/my-app. - Choose how it runs:
- Terminal opens the default Omarchy terminal with
xdg-terminal-exec, runs the command withbash -lc, and waits for a key after it finishes. - Background runs the same script with no window.
- Terminal opens the default Omarchy terminal with
- Pick a category. You can also pin an orbit slot (
1–6) and set an icon. - Save.
Launch it by clicking, with Enter, or with its orbit key. > restic finds it by title or by the command text. Right-click to copy the command, edit it, or delete it.
~/.local/bin is on the terminal PATH in Omarchy. A script saved there, with the executable bit set, can be launched by its file name alone:
install -m 755 ./restic-backup ~/.local/bin/restic-backupThe terminal window stays open when Terminal is selected, so the script itself does not need a “press a key” ending.
Add one from the terminal
Section titled “Add one from the terminal”Close Megamenu before this write, then open it again afterwards. --space and --category match the names you see in the menu. The same command in the same space is updated instead of added twice.
python3 ~/.config/omarchy/plugins/gruut.megamenu/scripts/add-command.py \ --title "Restic Backup" \ --command restic-backup \ --space "Home Lab" \ --category General \ --run terminal \ --slot 3--run background is the no-window choice. --slot 0 leaves the orbit pin unset.
