From ace2402c066d80c6916f52c47c083dc72f40ae00 Mon Sep 17 00:00:00 2001 From: iyear Date: Fri, 1 Nov 2024 14:40:56 +0800 Subject: [PATCH] fix(up): invalid default part size of uploader --- cmd/root.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/cmd/root.go b/cmd/root.go index 657172c371..a723a2ce10 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -122,9 +122,7 @@ func New() *cobra.Command { cmd.PersistentFlags().StringP(consts.FlagNamespace, "n", "default", "namespace for Telegram session") cmd.PersistentFlags().Bool(consts.FlagDebug, false, "enable debug mode") - cmd.PersistentFlags().IntP(consts.FlagPartSize, "s", 1024*1024, "part size for transfer, max is 1024*1024 bytes") - _ = cmd.PersistentFlags().MarkDeprecated(consts.FlagPartSize, "--size(-s) flag has been set to 1MiB(MAX) by default, and will be removed in the future") - + cmd.PersistentFlags().IntP(consts.FlagPartSize, "s", 512*1024, "part size for transfer") cmd.PersistentFlags().IntP(consts.FlagThreads, "t", 4, "max threads for transfer one item") cmd.PersistentFlags().IntP(consts.FlagLimit, "l", 2, "max number of concurrent tasks") cmd.PersistentFlags().Int(consts.FlagPoolSize, 8, "specify the size of the DC pool, zero means infinity")