Skip to content

Commit

Permalink
cmd: Preserve LastModified date when exporting storage (#5968)
Browse files Browse the repository at this point in the history
  • Loading branch information
jum committed Dec 13, 2023
1 parent cbbd1df commit 56c6b3f
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions cmd/storagefuncs.go
Original file line number Diff line number Diff line change
Expand Up @@ -200,9 +200,10 @@ func cmdExportStorage(fl Flags) (int, error) {
}

hdr := &tar.Header{
Name: k,
Mode: 0o600,
Size: int64(len(v)),
Name: k,
Mode: 0o600,
Size: int64(len(v)),
ModTime: info.Modified,
}

if err = tw.WriteHeader(hdr); err != nil {
Expand Down

0 comments on commit 56c6b3f

Please sign in to comment.