mirror of
https://github.com/octoleo/restic.git
synced 2024-11-21 20:35:12 +00:00
Merge pull request #4436 from MichaelEischer/add-snapshot-subfolder-syntax-to-help-text
Add snapshot subfolder syntax in help output of diff/dump/restore
This commit is contained in:
commit
e60c5b2d7f
@ -16,7 +16,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
var cmdDiff = &cobra.Command{
|
var cmdDiff = &cobra.Command{
|
||||||
Use: "diff [flags] snapshot-ID snapshot-ID",
|
Use: "diff [flags] snapshotID snapshotID",
|
||||||
Short: "Show differences between two snapshots",
|
Short: "Show differences between two snapshots",
|
||||||
Long: `
|
Long: `
|
||||||
The "diff" command shows differences from the first to the second snapshot. The
|
The "diff" command shows differences from the first to the second snapshot. The
|
||||||
@ -29,6 +29,10 @@ directory:
|
|||||||
* M The file's content was modified
|
* M The file's content was modified
|
||||||
* T The type was changed, e.g. a file was made a symlink
|
* T The type was changed, e.g. a file was made a symlink
|
||||||
|
|
||||||
|
To only compare files in specific subfolders, you can use the
|
||||||
|
"<snapshotID>:<subfolder>" syntax, where "subfolder" is a path within the
|
||||||
|
snapshot.
|
||||||
|
|
||||||
EXIT STATUS
|
EXIT STATUS
|
||||||
===========
|
===========
|
||||||
|
|
||||||
|
@ -24,9 +24,13 @@ single file is selected, it prints its contents to stdout. Folders are output
|
|||||||
as a tar (default) or zip file containing the contents of the specified folder.
|
as a tar (default) or zip file containing the contents of the specified folder.
|
||||||
Pass "/" as file name to dump the whole snapshot as an archive file.
|
Pass "/" as file name to dump the whole snapshot as an archive file.
|
||||||
|
|
||||||
The special snapshot "latest" can be used to use the latest snapshot in the
|
The special snapshotID "latest" can be used to use the latest snapshot in the
|
||||||
repository.
|
repository.
|
||||||
|
|
||||||
|
To include the folder content at the root of the archive, you can use the
|
||||||
|
"<snapshotID>:<subfolder>" syntax, where "subfolder" is a path within the
|
||||||
|
snapshot.
|
||||||
|
|
||||||
EXIT STATUS
|
EXIT STATUS
|
||||||
===========
|
===========
|
||||||
|
|
||||||
|
@ -25,9 +25,12 @@ var cmdRestore = &cobra.Command{
|
|||||||
The "restore" command extracts the data from a snapshot from the repository to
|
The "restore" command extracts the data from a snapshot from the repository to
|
||||||
a directory.
|
a directory.
|
||||||
|
|
||||||
The special snapshot "latest" can be used to restore the latest snapshot in the
|
The special snapshotID "latest" can be used to restore the latest snapshot in the
|
||||||
repository.
|
repository.
|
||||||
|
|
||||||
|
To only restore a specific subfolder, you can use the "<snapshotID>:<subfolder>"
|
||||||
|
syntax, where "subfolder" is a path within the snapshot.
|
||||||
|
|
||||||
EXIT STATUS
|
EXIT STATUS
|
||||||
===========
|
===========
|
||||||
|
|
||||||
|
@ -12,7 +12,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
var cmdTag = &cobra.Command{
|
var cmdTag = &cobra.Command{
|
||||||
Use: "tag [flags] [snapshot-ID ...]",
|
Use: "tag [flags] [snapshotID ...]",
|
||||||
Short: "Modify tags on snapshots",
|
Short: "Modify tags on snapshots",
|
||||||
Long: `
|
Long: `
|
||||||
The "tag" command allows you to modify tags on exiting snapshots.
|
The "tag" command allows you to modify tags on exiting snapshots.
|
||||||
@ -20,7 +20,7 @@ The "tag" command allows you to modify tags on exiting snapshots.
|
|||||||
You can either set/replace the entire set of tags on a snapshot, or
|
You can either set/replace the entire set of tags on a snapshot, or
|
||||||
add tags to/remove tags from the existing set.
|
add tags to/remove tags from the existing set.
|
||||||
|
|
||||||
When no snapshot-ID is given, all snapshots matching the host, tag and path filter criteria are modified.
|
When no snapshotID is given, all snapshots matching the host, tag and path filter criteria are modified.
|
||||||
|
|
||||||
EXIT STATUS
|
EXIT STATUS
|
||||||
===========
|
===========
|
||||||
|
Loading…
Reference in New Issue
Block a user