1
0
mirror of https://github.com/gilbertchen/duplicacy synced 2025-12-14 15:23:27 +00:00

Fix: backup to shared drive root

Allows writing to the drive root using:
gcd://driveid@ or gcd://driveid@/

To write to the root of the default user's drive use the special
shared drive named 'root':
gcd://root@/
This commit is contained in:
Richard Sanger
2019-11-27 00:00:40 +13:00
parent 426110e961
commit 7719bb9f29
2 changed files with 11 additions and 1 deletions

View File

@@ -264,6 +264,11 @@ func (storage *GCDStorage) getIDFromPath(threadIndex int, filePath string, creat
fileID = rootID
}
// Write directly to the root of the drive
if filePath == "" {
return fileID, nil
}
names := strings.Split(filePath, "/")
current := ""
for i, name := range names {