borgbackup/docs/usage/general.rst

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

45 lines
1.5 KiB
ReStructuredText
Raw Normal View History

2017-06-06 18:06:36 -04:00
General
-------
Borg consists of a number of commands. Each command accepts
a number of arguments and options and interprets various environment variables.
The following sections will describe each command in detail.
2025-09-04 14:29:43 -04:00
Commands, options, parameters, paths, and similar elements are shown in ``fixed-width``.
Option values are `underlined. Borg has a few options that accept a fixed set
of values (e.g., ``--encryption`` of :ref:`borg_repo-create`).
2017-06-17 08:29:14 -04:00
.. container:: experimental
Experimental features are marked with red stripes on the sides, like this paragraph.
Experimental features are not stable, which means that they may be changed in incompatible
ways or even removed entirely without prior notice in following releases.
.. include:: usage_general.rst.inc
2017-06-06 18:06:36 -04:00
If you are interested in more details (such as formulas), see
2017-06-06 18:06:36 -04:00
:ref:`internals`. For details on the available JSON output, refer to
:ref:`json_output`.
.. _common_options:
Common options
~~~~~~~~~~~~~~
All Borg commands share these options:
.. include:: common-options.rst.inc
Option ``--help`` when used as a command works as expected on subcommands (e.g., ``borg help compact``).
But it does not work when the help command is used on sub-sub-commands (e.g., ``borg help key export``).
The workaround for this is to use the help command as a flag (e.g., ``borg key export --help``).
Examples
~~~~~~~~
::
# Create an archive and log: borg version, files list, return code
2022-06-23 19:19:19 -04:00
$ borg -r /path/to/repo create --show-version --list --show-rc my-files files