doc(en/zh): add —delay in global-config doc

This commit is contained in:
XMLHexagram 2024-03-24 23:22:54 +08:00
parent 24ab0b50d9
commit eaf8395c6e
3 changed files with 26 additions and 1 deletions

View File

@ -99,7 +99,7 @@ func New() *cobra.Command {
cmd.PersistentFlags().Duration(consts.FlagReconnectTimeout, 5*time.Minute, "Telegram client reconnection backoff timeout, infinite if set to 0") // #158
cmd.PersistentFlags().String(consts.FlagTest, "", "use test Telegram client, only for developer")
cmd.PersistentFlags().Duration(consts.FlagDelay, 0, "delay between each download, forward and upload task")
cmd.PersistentFlags().Duration(consts.FlagDelay, 0, "set the delay between each download, forward and upload task")
// completion
_ = cmd.RegisterFlagCompletionFunc(consts.FlagNamespace, func(cmd *cobra.Command, args []string, toComplete string) ([]string, cobra.ShellCompDirective) {

View File

@ -87,3 +87,15 @@ Set higher timeout or 0(INF) if you want faster speed.
{{< command >}}
tdl --pool 2
{{< /command >}}
## `--delay`
set the delay between each download, forward and upload task. Default: `0s`.
{{< hint info >}}
Set higher delay time if you want to avoid flood ban.
{{< /hint >}}
{{< command >}}
tdl --delay 5s
{{< /command >}}

View File

@ -86,3 +86,16 @@ tdl --debug
{{< command >}}
tdl --pool 2
{{< /command >}}
## `--delay`
设置每个下载、转发和上传任务之间的延迟。默认值:`0s`。
{{< hint info >}}
如果你想避免因为短时间内产生大量请求被封禁,请设置更长的延迟时间。
{{< /hint >}}
{{< command >}}
tdl --delay 5s
{{< /command >}}