extract.rst.inc 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. .. IMPORTANT: this file is auto-generated from borg's built-in help, do not edit!
  2. .. borg:command:: borg extract
  3. .. _borg_extract:
  4. borg extract
  5. ------------
  6. ::
  7. borg [common options] extract <options> ARCHIVE PATH
  8. positional arguments
  9. ARCHIVE
  10. archive to extract
  11. PATH
  12. paths to extract; patterns are supported
  13. optional arguments
  14. ``--list``
  15. | output verbose list of items (files, dirs, ...)
  16. ``-n``, ``--dry-run``
  17. | do not actually change any files
  18. ``-e PATTERN``, ``--exclude PATTERN``
  19. | exclude paths matching PATTERN
  20. ``--exclude-from EXCLUDEFILE``
  21. | read exclude patterns from EXCLUDEFILE, one per line
  22. ``--pattern PATTERN``
  23. | include/exclude paths matching PATTERN
  24. ``--patterns-from PATTERNFILE``
  25. | read include/exclude patterns from PATTERNFILE, one per line
  26. ``--numeric-owner``
  27. | only obey numeric user and group identifiers
  28. ``--strip-components NUMBER``
  29. | Remove the specified number of leading path elements. Pathnames with fewer elements will be silently skipped.
  30. ``--stdout``
  31. | write all extracted data to stdout
  32. ``--sparse``
  33. | create holes in output sparse file from all-zero chunks
  34. `Common options`_
  35. |
  36. Description
  37. ~~~~~~~~~~~
  38. This command extracts the contents of an archive. By default the entire
  39. archive is extracted but a subset of files and directories can be selected
  40. by passing a list of ``PATHs`` as arguments. The file selection can further
  41. be restricted by using the ``--exclude`` option.
  42. See the output of the "borg help patterns" command for more help on exclude patterns.
  43. By using ``--dry-run``, you can do all extraction steps except actually writing the
  44. output data: reading metadata and data chunks from the repo, checking the hash/hmac,
  45. decrypting, decompressing.
  46. ``--progress`` can be slower than no progress display, since it makes one additional
  47. pass over the archive metadata.