1
0
mirror of https://github.com/rclone/rclone.git synced 2025-12-16 00:04:40 +00:00

fs: Add --max-duration flag to control the maximum duration of a transfer session

This gives you more control over how long rclone will run for, making
it easier to script backups, e.g. via cron. Once the `--max-duration`
time limit is reached, no new transfers will be initiated, but those
already in-flight will be allowed to complete.

Fixes #985
This commit is contained in:
boosh
2019-07-25 11:28:27 +01:00
committed by Nick Craig-Wood
parent e4d2d228bd
commit 0d7573dd81
5 changed files with 71 additions and 1 deletions

View File

@@ -716,6 +716,17 @@ files not recursed through are considered excluded and will be deleted
on the destination. Test first with `--dry-run` if you are not sure
what will happen.
### --max-duration=TIME ###
Rclone will stop scheduling new transfers when it has run for the
duration specified.
Defaults to off.
When the limit is reached any existing transfers will complete.
Rclone won't exit with an error if the transfer limit is reached.
### --max-transfer=SIZE ###
Rclone will stop transferring when it has reached the size specified.