borg-list.1 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242
  1. .\" Man page generated from reStructuredText.
  2. .
  3. .
  4. .nr rst2man-indent-level 0
  5. .
  6. .de1 rstReportMargin
  7. \\$1 \\n[an-margin]
  8. level \\n[rst2man-indent-level]
  9. level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
  10. -
  11. \\n[rst2man-indent0]
  12. \\n[rst2man-indent1]
  13. \\n[rst2man-indent2]
  14. ..
  15. .de1 INDENT
  16. .\" .rstReportMargin pre:
  17. . RS \\$1
  18. . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
  19. . nr rst2man-indent-level +1
  20. .\" .rstReportMargin post:
  21. ..
  22. .de UNINDENT
  23. . RE
  24. .\" indent \\n[an-margin]
  25. .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
  26. .nr rst2man-indent-level -1
  27. .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
  28. .in \\n[rst2man-indent\\n[rst2man-indent-level]]u
  29. ..
  30. .TH "BORG-LIST" 1 "2022-06-26" "" "borg backup tool"
  31. .SH NAME
  32. borg-list \- List archive contents
  33. .SH SYNOPSIS
  34. .sp
  35. borg [common options] list [options] NAME [PATH...]
  36. .SH DESCRIPTION
  37. .sp
  38. This command lists the contents of an archive.
  39. .sp
  40. For more help on include/exclude patterns, see the \fIborg_patterns\fP command output.
  41. .SH OPTIONS
  42. .sp
  43. See \fIborg\-common(1)\fP for common options of Borg commands.
  44. .SS arguments
  45. .INDENT 0.0
  46. .TP
  47. .B NAME
  48. specify the archive name
  49. .TP
  50. .B PATH
  51. paths to list; patterns are supported
  52. .UNINDENT
  53. .SS optional arguments
  54. .INDENT 0.0
  55. .TP
  56. .B \-\-short
  57. only print file/directory names, nothing else
  58. .TP
  59. .BI \-\-format \ FORMAT
  60. specify format for file listing (default: "{mode} {user:6} {group:6} {size:8} {mtime} {path}{extra}{NL}")
  61. .TP
  62. .B \-\-json\-lines
  63. Format output as JSON Lines. The form of \fB\-\-format\fP 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.
  64. .UNINDENT
  65. .SS Exclusion options
  66. .INDENT 0.0
  67. .TP
  68. .BI \-e \ PATTERN\fR,\fB \ \-\-exclude \ PATTERN
  69. exclude paths matching PATTERN
  70. .TP
  71. .BI \-\-exclude\-from \ EXCLUDEFILE
  72. read exclude patterns from EXCLUDEFILE, one per line
  73. .TP
  74. .BI \-\-pattern \ PATTERN
  75. include/exclude paths matching PATTERN
  76. .TP
  77. .BI \-\-patterns\-from \ PATTERNFILE
  78. read include/exclude patterns from PATTERNFILE, one per line
  79. .UNINDENT
  80. .SH EXAMPLES
  81. .INDENT 0.0
  82. .INDENT 3.5
  83. .sp
  84. .nf
  85. .ft C
  86. $ borg list root\-2016\-02\-15
  87. drwxr\-xr\-x root root 0 Mon, 2016\-02\-15 17:44:27 .
  88. drwxrwxr\-x root root 0 Mon, 2016\-02\-15 19:04:49 bin
  89. \-rwxr\-xr\-x root root 1029624 Thu, 2014\-11\-13 00:08:51 bin/bash
  90. lrwxrwxrwx root root 0 Fri, 2015\-03\-27 20:24:26 bin/bzcmp \-> bzdiff
  91. \-rwxr\-xr\-x root root 2140 Fri, 2015\-03\-27 20:24:22 bin/bzdiff
  92. \&...
  93. $ borg list root\-2016\-02\-15 \-\-pattern "\- bin/ba*"
  94. drwxr\-xr\-x root root 0 Mon, 2016\-02\-15 17:44:27 .
  95. drwxrwxr\-x root root 0 Mon, 2016\-02\-15 19:04:49 bin
  96. lrwxrwxrwx root root 0 Fri, 2015\-03\-27 20:24:26 bin/bzcmp \-> bzdiff
  97. \-rwxr\-xr\-x root root 2140 Fri, 2015\-03\-27 20:24:22 bin/bzdiff
  98. \&...
  99. $ borg list archiveA \-\-format="{mode} {user:6} {group:6} {size:8d} {isomtime} {path}{extra}{NEWLINE}"
  100. drwxrwxr\-x user user 0 Sun, 2015\-02\-01 11:00:00 .
  101. drwxrwxr\-x user user 0 Sun, 2015\-02\-01 11:00:00 code
  102. drwxrwxr\-x user user 0 Sun, 2015\-02\-01 11:00:00 code/myproject
  103. \-rw\-rw\-r\-\- user user 1416192 Sun, 2015\-02\-01 11:00:00 code/myproject/file.ext
  104. \-rw\-rw\-r\-\- user user 1416192 Sun, 2015\-02\-01 11:00:00 code/myproject/file.text
  105. \&...
  106. $ borg list archiveA \-\-pattern \(aqre:\e.ext$\(aq
  107. \-rw\-rw\-r\-\- user user 1416192 Sun, 2015\-02\-01 11:00:00 code/myproject/file.ext
  108. \&...
  109. $ borg list archiveA \-\-pattern \(aqre:.ext$\(aq
  110. \-rw\-rw\-r\-\- user user 1416192 Sun, 2015\-02\-01 11:00:00 code/myproject/file.ext
  111. \-rw\-rw\-r\-\- user user 1416192 Sun, 2015\-02\-01 11:00:00 code/myproject/file.text
  112. \&...
  113. .ft P
  114. .fi
  115. .UNINDENT
  116. .UNINDENT
  117. .SH NOTES
  118. .SS The FORMAT specifier syntax
  119. .sp
  120. The \fB\-\-format\fP option uses python\(aqs \fI\%format string syntax\fP\&.
  121. .sp
  122. Examples:
  123. .INDENT 0.0
  124. .INDENT 3.5
  125. .sp
  126. .nf
  127. .ft C
  128. $ borg list \-\-format \(aq{mode} {user:6} {group:6} {size:8} {mtime} {path}{extra}{NL}\(aq ArchiveFoo
  129. \-rw\-rw\-r\-\- user user 1024 Thu, 2021\-12\-09 10:22:17 file\-foo
  130. \&...
  131. # {VAR:<NUMBER} \- pad to NUMBER columns left\-aligned.
  132. # {VAR:>NUMBER} \- pad to NUMBER columns right\-aligned.
  133. $ borg list \-\-format \(aq{mode} {user:>6} {group:>6} {size:<8} {mtime} {path}{extra}{NL}\(aq ArchiveFoo
  134. \-rw\-rw\-r\-\- user user 1024 Thu, 2021\-12\-09 10:22:17 file\-foo
  135. \&...
  136. .ft P
  137. .fi
  138. .UNINDENT
  139. .UNINDENT
  140. .sp
  141. The following keys are always available:
  142. \- NEWLINE: OS dependent line separator
  143. \- NL: alias of NEWLINE
  144. \- NUL: NUL character for creating print0 / xargs \-0 like output, see barchive and bpath keys below
  145. \- SPACE
  146. \- TAB
  147. \- CR
  148. \- LF
  149. .sp
  150. Keys available only when listing files in an archive:
  151. .INDENT 0.0
  152. .IP \(bu 2
  153. type
  154. .IP \(bu 2
  155. mode
  156. .IP \(bu 2
  157. uid
  158. .IP \(bu 2
  159. gid
  160. .IP \(bu 2
  161. user
  162. .IP \(bu 2
  163. group
  164. .IP \(bu 2
  165. path: path interpreted as text (might be missing non\-text characters, see bpath)
  166. .IP \(bu 2
  167. bpath: verbatim POSIX path, can contain any character except NUL
  168. .IP \(bu 2
  169. source: link target for symlinks (identical to linktarget)
  170. .IP \(bu 2
  171. linktarget
  172. .IP \(bu 2
  173. hlid: hard link identity (same if hardlinking same fs object)
  174. .IP \(bu 2
  175. flags
  176. .IP \(bu 2
  177. size
  178. .IP \(bu 2
  179. dsize: deduplicated size
  180. .IP \(bu 2
  181. num_chunks: number of chunks in this file
  182. .IP \(bu 2
  183. unique_chunks: number of unique chunks in this file
  184. .IP \(bu 2
  185. mtime
  186. .IP \(bu 2
  187. ctime
  188. .IP \(bu 2
  189. atime
  190. .IP \(bu 2
  191. isomtime
  192. .IP \(bu 2
  193. isoctime
  194. .IP \(bu 2
  195. isoatime
  196. .IP \(bu 2
  197. blake2b
  198. .IP \(bu 2
  199. blake2s
  200. .IP \(bu 2
  201. md5
  202. .IP \(bu 2
  203. sha1
  204. .IP \(bu 2
  205. sha224
  206. .IP \(bu 2
  207. sha256
  208. .IP \(bu 2
  209. sha384
  210. .IP \(bu 2
  211. sha3_224
  212. .IP \(bu 2
  213. sha3_256
  214. .IP \(bu 2
  215. sha3_384
  216. .IP \(bu 2
  217. sha3_512
  218. .IP \(bu 2
  219. sha512
  220. .IP \(bu 2
  221. xxh64: XXH64 checksum of this file (note: this is NOT a cryptographic hash!)
  222. .IP \(bu 2
  223. archiveid
  224. .IP \(bu 2
  225. archivename
  226. .IP \(bu 2
  227. extra: prepends {source} with " \-> " for soft links and " link to " for hard links
  228. .IP \(bu 2
  229. health: either "healthy" (file ok) or "broken" (if file has all\-zero replacement chunks)
  230. .UNINDENT
  231. .SH SEE ALSO
  232. .sp
  233. \fIborg\-common(1)\fP, \fIborg\-info(1)\fP, \fIborg\-diff(1)\fP, \fIborg\-prune(1)\fP, \fIborg\-patterns(1)\fP
  234. .SH AUTHOR
  235. The Borg Collective
  236. .\" Generated by docutils manpage writer.
  237. .