1
0
mirror of https://github.com/rclone/rclone.git synced 2026-01-06 02:23:24 +00:00

Add a delete threshold to sync (--max-delete)

Fixes #959
This commit is contained in:
Bjørn Erik Pedersen
2018-01-22 19:53:18 +01:00
committed by Nick Craig-Wood
parent cd7fd51119
commit ab8c0a81fa
5 changed files with 37 additions and 1 deletions

View File

@@ -41,6 +41,7 @@ type ConfigInfo struct {
Dump DumpFlags
InsecureSkipVerify bool // Skip server certificate verification
DeleteMode DeleteMode
MaxDelete int64
TrackRenames bool // Track file renames.
LowLevelRetries int
UpdateOlder bool // Skip files that are newer on the destination
@@ -82,6 +83,7 @@ func NewConfig() *ConfigInfo {
c.ConnectTimeout = 60 * time.Second
c.Timeout = 5 * 60 * time.Second
c.DeleteMode = DeleteModeDefault
c.MaxDelete = -1
c.LowLevelRetries = 10
c.MaxDepth = -1
c.DataRateUnit = "bytes"