mirror of
https://github.com/octoleo/restic.git
synced 2024-12-22 02:48:55 +00:00
Add error to messages
This commit is contained in:
parent
629935db5c
commit
0a4c9aab36
@ -21,12 +21,12 @@ func commandRestore(repo *khepri.Repository, args []string) error {
|
|||||||
|
|
||||||
sn, err := khepri.LoadSnapshot(repo, id)
|
sn, err := khepri.LoadSnapshot(repo, id)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Fatalf("error loading snapshot %s", id)
|
log.Fatalf("error loading snapshot %s: %v", id, err)
|
||||||
}
|
}
|
||||||
|
|
||||||
err = sn.RestoreAt(target)
|
err = sn.RestoreAt(target)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Fatalf("error restoring snapshot %s", id)
|
log.Fatalf("error restoring snapshot %s: %v", id, err)
|
||||||
}
|
}
|
||||||
|
|
||||||
log.Printf("%q restored to %q\n", id, target)
|
log.Printf("%q restored to %q\n", id, target)
|
||||||
|
Loading…
Reference in New Issue
Block a user