list.rst.inc 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. .. IMPORTANT: this file is auto-generated from borg's built-in help, do not edit!
  2. .. _borg_list:
  3. borg list
  4. ---------
  5. .. code-block:: none
  6. borg [common options] list [options] REPOSITORY_OR_ARCHIVE PATH
  7. positional arguments
  8. REPOSITORY_OR_ARCHIVE
  9. repository/archive to list contents of
  10. PATH
  11. paths to list; patterns are supported
  12. optional arguments
  13. ``--short``
  14. | only print file/directory names, nothing else
  15. ``--format``, ``--list-format``
  16. | specify format for file listing
  17. | (default: "{mode} {user:6} {group:6} {size:8d} {isomtime} {path}{extra}{NL}")
  18. ``--json``
  19. | Only valid for listing repository contents. Format output as JSON. The form of ``--format`` is ignored, but keys used in it are added to the JSON output. Some keys are always present. Note: JSON can only represent text. A "barchive" key is therefore not available.
  20. ``--json-lines``
  21. | Only valid for listing archive contents. Format output as JSON Lines. The form of ``--format`` is ignored, but keys used in it are added to the JSON output. Some keys are always present. Note: JSON can only represent text. A "bpath" key is therefore not available.
  22. :ref:`common_options`
  23. |
  24. filters
  25. ``-P``, ``--prefix``
  26. | only consider archive names starting with this prefix.
  27. ``-a``, ``--glob-archives``
  28. | only consider archive names matching the glob. sh: rules apply, see "borg help patterns". ``--prefix`` and ``--glob-archives`` are mutually exclusive.
  29. ``--sort-by``
  30. | Comma-separated list of sorting keys; valid keys are: timestamp, name, id; default is: timestamp
  31. ``--first N``
  32. | consider first N archives after other filters were applied
  33. ``--last N``
  34. | consider last N archives after other filters were applied
  35. Exclusion options
  36. ``-e PATTERN``, ``--exclude PATTERN``
  37. | exclude paths matching PATTERN
  38. ``--exclude-from EXCLUDEFILE``
  39. | read exclude patterns from EXCLUDEFILE, one per line
  40. ``--exclude-caches``
  41. | exclude directories that contain a CACHEDIR.TAG file (http://www.brynosaurus.com/cachedir/spec.html)
  42. ``--exclude-if-present NAME``
  43. | exclude directories that are tagged by containing a filesystem object with the given NAME
  44. ``--keep-exclude-tags``, ``--keep-tag-files``
  45. | if tag objects are specified with --exclude-if-present, don't omit the tag objects themselves from the backup archive
  46. ``--pattern PATTERN``
  47. | experimental: include/exclude paths matching PATTERN
  48. ``--patterns-from PATTERNFILE``
  49. | experimental: read include/exclude patterns from PATTERNFILE, one per line
  50. Description
  51. ~~~~~~~~~~~
  52. This command lists the contents of a repository or an archive.
  53. See the "borg help patterns" command for more help on exclude patterns.
  54. .. man NOTES
  55. The following keys are available for ``--format``:
  56. - NEWLINE: OS dependent line separator
  57. - NL: alias of NEWLINE
  58. - NUL: NUL character for creating print0 / xargs -0 like output, see barchive/bpath
  59. - SPACE
  60. - TAB
  61. - CR
  62. - LF
  63. Keys for listing repository archives:
  64. - archive, name: archive name interpreted as text (might be missing non-text characters, see barchive)
  65. - barchive: verbatim archive name, can contain any character except NUL
  66. - time: time of creation of the archive
  67. - id: internal ID of the archive
  68. Keys for listing archive files:
  69. - type
  70. - mode
  71. - uid
  72. - gid
  73. - user
  74. - group
  75. - path: path interpreted as text (might be missing non-text characters, see bpath)
  76. - bpath: verbatim POSIX path, can contain any character except NUL
  77. - source: link target for links (identical to linktarget)
  78. - linktarget
  79. - flags
  80. - size
  81. - csize: compressed size
  82. - dsize: deduplicated size
  83. - dcsize: deduplicated compressed size
  84. - num_chunks: number of chunks in this file
  85. - unique_chunks: number of unique chunks in this file
  86. - mtime
  87. - ctime
  88. - atime
  89. - isomtime
  90. - isoctime
  91. - isoatime
  92. - blake2b
  93. - blake2s
  94. - md5
  95. - sha1
  96. - sha224
  97. - sha256
  98. - sha384
  99. - sha3_224
  100. - sha3_256
  101. - sha3_384
  102. - sha3_512
  103. - sha512
  104. - shake_128
  105. - shake_256
  106. - archiveid
  107. - archivename
  108. - extra: prepends {source} with " -> " for soft links and " link to " for hard links
  109. - health: either "healthy" (file ok) or "broken" (if file has all-zero replacement chunks)