forked from TrueCloudLab/restic
snapshots: also show snapshot size in compact view
This commit is contained in:
parent
b71a885b92
commit
f980f5647e
2 changed files with 4 additions and 0 deletions
|
@ -10,3 +10,4 @@ statistics use `restic snapshots --json` or `restic cat snapshot <snapshotID>`.
|
|||
|
||||
https://github.com/restic/restic/issues/693
|
||||
https://github.com/restic/restic/pull/4705
|
||||
https://github.com/restic/restic/pull/4913
|
||||
|
|
|
@ -190,6 +190,9 @@ func PrintSnapshots(stdout io.Writer, list restic.Snapshots, reasons []restic.Ke
|
|||
tab.AddColumn("Time", "{{ .Timestamp }}")
|
||||
tab.AddColumn("Host", "{{ .Hostname }}")
|
||||
tab.AddColumn("Tags ", `{{ join .Tags "\n" }}`)
|
||||
if hasSize {
|
||||
tab.AddColumn("Size", `{{ .Size }}`)
|
||||
}
|
||||
} else {
|
||||
tab.AddColumn("ID", "{{ .ID }}")
|
||||
tab.AddColumn("Time", "{{ .Timestamp }}")
|
||||
|
|
Loading…
Reference in a new issue