mpm dump - Snapshot installed packages to a TOML manifest or a
Brewfile.
mpm dump [OPTIONS] [OUTPUT_PATH]
Dump installed packages to a TOML manifest or a Brewfile.
By default emits TOML, one section per manager (one entry per
package, keyed by package ID, with the installed version as the value). Pass
`--brewfile` to emit a Brewfile compatible with `brew bundle install`.
With no [OUTPUT_PATH] argument, writes to stdout. TOML files are
readable by `mpm restore`.
With `--query`, restrict the snapshot to installed packages whose
ID or name matches it (fuzzy by default, verbatim with `--exact`).
`--merge` and `--update-version` operate on an existing TOML file;
both require the [OUTPUT_PATH] argument and neither is valid with
`--brewfile`.
- [OUTPUT_PATH]
- --toml
- Emit a TOML manifest with one section per manager. Default.
- --brewfile
- Emit a Brewfile that `brew bundle install` can consume. Only managers
natively supported by brew bundle are included. Other managers are tallied
in the header and excluded from the output.
- --overwrite /
--force / --replace
- Allow the target file to be silently wiped out if it already exists.
- Include a metadata + warning comment block at the top of the output.
- --merge
- TOML only. Read the provided file and add each new entry to it. Requires
the [OUTPUT_PATH] argument.
- --update-version
- TOML only. Read the provided file and update each existing entry with the
version currently installed on the system. Requires the [OUTPUT_PATH]
argument.
- --query
QUERY
- Only keep installed packages whose ID or name matches QUERY. Fuzzy by
default (case-insensitive, tokenized); see --exact.
- --exact /
--fuzzy
- With --query, require a verbatim match on the package ID or name instead
of the default fuzzy match. No effect without --query.
- -h / --help
- Show this message and exit.
- DUMP_OUTPUT_FORMAT
- Emit a TOML manifest with one section per manager. Default.
- DUMP_OVERWRITE
- Allow the target file to be silently wiped out if it already exists.
- Include a metadata + warning comment block at the top of the output.
- DUMP_MERGE
- TOML only. Read the provided file and add each new entry to it. Requires
the [OUTPUT_PATH] argument.
- DUMP_UPDATE_VERSION
- TOML only. Read the provided file and update each existing entry with the
version currently installed on the system. Requires the [OUTPUT_PATH]
argument.
- DUMP_QUERY
- Only keep installed packages whose ID or name matches QUERY. Fuzzy by
default (case-insensitive, tokenized); see --exact.
- DUMP_EXACT
- With --query, require a verbatim match on the package ID or name instead
of the default fuzzy match. No effect without --query.
- DUMP_HELP
- Show this message and exit.
- 0
- Success.
- 1
- A runtime error, or an aborted prompt (Ctrl-C, a declined
confirmation).
- 2
- A usage error: unknown option, invalid value, missing operand, or an
unparsable configuration file.