maqpna alias install
Add a short alias for maqpna (default ma) with completion to your shell's startup file
Synopsis#
maqpna alias install [--name ma] [--shell bash|zsh|fish|powershell] [--rc FILE] [--force]Description#
From the help of maqpna alias:
install adds a shell function NAME (default ma) that runs maqpna, with tab completion, to your shell's startup file (bash ~/.bashrc, zsh ~/.zshrc, fish ~/.config/fish/config.fish, PowerShell $PROFILE), between "# >>> maqpna alias NAME >>>" markers: running it again replaces the block, uninstall removes it. It refuses a NAME that is already a command on PATH unless --force. Help and errors then name the alias (maqpna sets MAQPNA_PROG_NAME). Open a new shell, or source the file, to use it.
The binary itself also answers to maqpnactl and ma: the install scripts link ma next to maqpna when no ma exists on PATH. Package managers (Homebrew, Scoop, winget) do not install ma; use this command.
Flags#
| Flag | Type | Description | Default |
|---|---|---|---|
--force | switch | install even when NAME is already a command on PATH | none |
--name | string | the alias name | ma |
--rc | string | the startup file to edit (default: the shell's) | none |
--shell | string | bash | zsh | fish | powershell (default: from $SHELL) | zsh |
The global flags (--context, -o, --no-color, ...) work with every command.
Examples#
maqpna alias install
maqpna alias install --name mq --shell zshWhat happens when you run it#
--force: install even when NAME is already a command on PATH.
Exit codes#
| Code | Meaning |
|---|---|
0 | success |
1 | error (the message says what failed, with a hint when there is one) |
2 | usage error: unknown flag, missing argument or bad value; the synopsis is printed |
3 | a check failed, a change is blocked, or a result did not match (tamper, policy mismatch) (not used by this command) |