mirror of
https://github.com/IceWhaleTech/CasaOS.git
synced 2025-12-23 04:54:41 +00:00
Compare commits
1 Commits
fix/resp
...
v0.4.4-alp
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a106abc8ba |
@@ -431,7 +431,9 @@ func AddFile(ar archiver.Writer, path, commonPath string) error {
|
||||
defer file.Close()
|
||||
|
||||
if path != commonPath {
|
||||
filename := info.Name()
|
||||
//filename := info.Name()
|
||||
filename := strings.TrimPrefix(path, commonPath)
|
||||
filename = strings.TrimPrefix(filename, string(filepath.Separator))
|
||||
err = ar.Write(archiver.File{
|
||||
FileInfo: archiver.FileInfo{
|
||||
FileInfo: info,
|
||||
|
||||
Reference in New Issue
Block a user