gecko-dev/python/mach
Andrew Halberstadt ef21656e00 Bug 1519990 - [mach] Add ability to generate completion scripts via 'mach mach-completion <shell>', r=mhentges
Supported shells are 'bash', 'zsh' and 'fish'. Here are installation
instructions with various shells and contexts:

### bash

    $ mach mach-completion bash -f _mach
    $ sudo mv _mach /etc/bash_completion.d

### bash (homebrew)

    $ mach mach-completion bash -f $(brew --prefix)/etc/bash_completion.d/mach.bash-completion

### zsh

    $ mkdir ~/.zfunc
    $ mach mach-completion zsh -f ~/.zfunc/_mach

then edit ~/.zshrc and add:

    fpath += ~/.zfunc
    autoload -U compinit && compinit

### zsh (oh-my-zsh)

    $ mkdir $ZSH/plugins/mach
    $ mach mach-completion zsh -f $ZSH/plugins/mach/_mach

then edit ~/.zshrc and add 'mach' to your enabled plugins:

    plugins(mach ...)

### zsh (prezto)

    $ mach mach-completion zsh -f ~/.zprezto/modules/completion/external/src/_mach

### fish

    $ ./mach mach-completion fish -f ~/.config/fish/completions/mach.fish

### fish (homebrew)

    $ ./mach mach-completion fish -f (brew --prefix)/share/fish/vendor_completions.d/mach.fish

Differential Revision: https://phabricator.services.mozilla.com/D90416
2020-10-09 16:03:30 +00:00
..
docs Bug 1519990 - [mach] Add ability to generate completion scripts via 'mach mach-completion <shell>', r=mhentges 2020-10-09 16:03:30 +00:00
mach Bug 1519990 - [mach] Add ability to generate completion scripts via 'mach mach-completion <shell>', r=mhentges 2020-10-09 16:03:30 +00:00
README.rst
bash-completion.sh
metrics.yaml Bug 1654074: Publish glean handle to mach commands r=firefox-build-system-reviewers,rstewart 2020-09-15 21:15:20 +00:00
pings.yaml Bug 1654074: Publish glean handle to mach commands r=firefox-build-system-reviewers,rstewart 2020-09-15 21:15:20 +00:00
setup.cfg
setup.py

README.rst

====
mach
====

Mach (German for *do*) is a generic command dispatcher for the command
line.

To use mach, you install the mach core (a Python package), create an
executable *driver* script (named whatever you want), and write mach
commands. When the *driver* is executed, mach dispatches to the
requested command handler automatically.

To learn more, read the docs in ``docs/``.