mirror of
https://github.com/restic/restic.git
synced 2025-03-15 08:30:51 +00:00
Merge pull request #4296 from MichaelEischer/rewrite-reorder-output
rewrite: log snapshot saved before removal of the old snapshot
This commit is contained in:
commit
4503aea0df
@ -136,6 +136,7 @@ func rewriteSnapshot(ctx context.Context, repo *repository.Repository, sn *resti
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return false, err
|
return false, err
|
||||||
}
|
}
|
||||||
|
Verbosef("saved new snapshot %v\n", id.Str())
|
||||||
|
|
||||||
if opts.Forget {
|
if opts.Forget {
|
||||||
h := restic.Handle{Type: restic.SnapshotFile, Name: sn.ID().String()}
|
h := restic.Handle{Type: restic.SnapshotFile, Name: sn.ID().String()}
|
||||||
@ -145,7 +146,6 @@ func rewriteSnapshot(ctx context.Context, repo *repository.Repository, sn *resti
|
|||||||
debug.Log("removed old snapshot %v", sn.ID())
|
debug.Log("removed old snapshot %v", sn.ID())
|
||||||
Verbosef("removed old snapshot %v\n", sn.ID().Str())
|
Verbosef("removed old snapshot %v\n", sn.ID().Str())
|
||||||
}
|
}
|
||||||
Verbosef("saved new snapshot %v\n", id.Str())
|
|
||||||
return true, nil
|
return true, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user