borg-diff.1 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133
  1. .\" Man page generated from reStructuredText.
  2. .
  3. .TH BORG-DIFF 1 "2017-02-11" "" "borg backup tool"
  4. .SH NAME
  5. borg-diff \- Diff contents of two archives
  6. .
  7. .nr rst2man-indent-level 0
  8. .
  9. .de1 rstReportMargin
  10. \\$1 \\n[an-margin]
  11. level \\n[rst2man-indent-level]
  12. level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
  13. -
  14. \\n[rst2man-indent0]
  15. \\n[rst2man-indent1]
  16. \\n[rst2man-indent2]
  17. ..
  18. .de1 INDENT
  19. .\" .rstReportMargin pre:
  20. . RS \\$1
  21. . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
  22. . nr rst2man-indent-level +1
  23. .\" .rstReportMargin post:
  24. ..
  25. .de UNINDENT
  26. . RE
  27. .\" indent \\n[an-margin]
  28. .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
  29. .nr rst2man-indent-level -1
  30. .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
  31. .in \\n[rst2man-indent\\n[rst2man-indent-level]]u
  32. ..
  33. .SH SYNOPSIS
  34. .sp
  35. borg diff <options> REPO_ARCHIVE1 ARCHIVE2 PATH
  36. .SH DESCRIPTION
  37. .sp
  38. This command finds differences (file contents, user/group/mode) between archives.
  39. .sp
  40. A repository location and an archive name must be specified for REPO_ARCHIVE1.
  41. ARCHIVE2 is just another archive name in same repository (no repository location
  42. allowed).
  43. .sp
  44. For archives created with Borg 1.1 or newer diff automatically detects whether
  45. the archives are created with the same chunker params. If so, only chunk IDs
  46. are compared, which is very fast.
  47. .sp
  48. For archives prior to Borg 1.1 chunk contents are compared by default.
  49. If you did not create the archives with different chunker params,
  50. pass \-\-same\-chunker\-params.
  51. Note that the chunker params changed from Borg 0.xx to 1.0.
  52. .sp
  53. See the output of the "borg help patterns" command for more help on exclude patterns.
  54. .SH OPTIONS
  55. .sp
  56. See \fIborg\-common(1)\fP for common options of Borg commands.
  57. .SS arguments
  58. .INDENT 0.0
  59. .TP
  60. .B REPO_ARCHIVE1
  61. repository location and ARCHIVE1 name
  62. .TP
  63. .B ARCHIVE2
  64. ARCHIVE2 name (no repository location allowed)
  65. .TP
  66. .B PATH
  67. paths of items inside the archives to compare; patterns are supported
  68. .UNINDENT
  69. .SS optional arguments
  70. .INDENT 0.0
  71. .TP
  72. .BI \-e \ PATTERN\fP,\fB \ \-\-exclude \ PATTERN
  73. exclude paths matching PATTERN
  74. .TP
  75. .BI \-\-exclude\-from \ EXCLUDEFILE
  76. read exclude patterns from EXCLUDEFILE, one per line
  77. .TP
  78. .B \-\-numeric\-owner
  79. only consider numeric user and group identifiers
  80. .TP
  81. .B \-\-same\-chunker\-params
  82. Override check of chunker parameters.
  83. .TP
  84. .B \-\-sort
  85. Sort the output lines by file path.
  86. .UNINDENT
  87. .SH EXAMPLES
  88. .INDENT 0.0
  89. .INDENT 3.5
  90. .sp
  91. .nf
  92. .ft C
  93. $ borg init \-e=none testrepo
  94. $ mkdir testdir
  95. $ cd testdir
  96. $ echo asdf > file1
  97. $ dd if=/dev/urandom bs=1M count=4 > file2
  98. $ touch file3
  99. $ borg create ../testrepo::archive1 .
  100. $ chmod a+x file1
  101. $ echo "something" >> file2
  102. $ borg create ../testrepo::archive2 .
  103. $ rm file3
  104. $ touch file4
  105. $ borg create ../testrepo::archive3 .
  106. $ cd ..
  107. $ borg diff testrepo::archive1 archive2
  108. [\-rw\-r\-\-r\-\- \-> \-rwxr\-xr\-x] file1
  109. +135 B \-252 B file2
  110. $ borg diff testrepo::archive2 archive3
  111. added 0 B file4
  112. removed 0 B file3
  113. $ borg diff testrepo::archive1 archive3
  114. [\-rw\-r\-\-r\-\- \-> \-rwxr\-xr\-x] file1
  115. +135 B \-252 B file2
  116. added 0 B file4
  117. removed 0 B file3
  118. .ft P
  119. .fi
  120. .UNINDENT
  121. .UNINDENT
  122. .SH SEE ALSO
  123. .sp
  124. \fIborg\-common(1)\fP
  125. .SH AUTHOR
  126. The Borg Collective
  127. .\" Generated by docutils manpage writer.
  128. .