From 3f06e2690545c77b9fc5c528aee1c0ca06372555 Mon Sep 17 00:00:00 2001 From: Sxci Date: Wed, 1 Jul 2020 14:55:24 +0800 Subject: [PATCH 1/2] update readme --- README.md | 12 ++++++------ cmd/root.go | 9 ++++++++- 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 8d85db65..502e48f0 100644 --- a/README.md +++ b/README.md @@ -14,12 +14,12 @@ qshell是利用[七牛文档上公开的API](http://developer.qiniu.com)实现 |版本 |支持平台|链接| |--------|---------|----| -|qshell v2.4.1|Windows X86|[下载](http://devtools.qiniu.com/qshell-windows-x86-v2.4.1.exe.zip) -|qshell v2.4.1|Windows amd64|[下载](http://devtools.qiniu.com/qshell-windows-x64-v2.4.1.exe.zip) -|qshell v2.4.1|Linux X86|[下载](http://devtools.qiniu.com/qshell-linux-x86-v2.4.1.zip) -|qshell v2.4.1|Linux amd64|[下载](http://devtools.qiniu.com/qshell-linux-x64-v2.4.1.zip) -|qshell v2.4.1|Linux Arm|[下载](http://devtools.qiniu.com/qshell-linux-arm-v2.4.1.zip) -|qshell v2.4.1|Mac OS |[下载](http://devtools.qiniu.com/qshell-darwin-x64-v2.4.1.zip) +|qshell v2.4.2|Windows X86|[下载](http://devtools.qiniu.com/qshell-windows-x86-v2.4.2.exe.zip) +|qshell v2.4.2|Windows amd64|[下载](http://devtools.qiniu.com/qshell-windows-x64-v2.4.2.exe.zip) +|qshell v2.4.2|Linux X86|[下载](http://devtools.qiniu.com/qshell-linux-x86-v2.4.2.zip) +|qshell v2.4.2|Linux amd64|[下载](http://devtools.qiniu.com/qshell-linux-x64-v2.4.2.zip) +|qshell v2.4.2|Linux Arm|[下载](http://devtools.qiniu.com/qshell-linux-arm-v2.4.2.zip) +|qshell v2.4.2|Mac OS |[下载](http://devtools.qiniu.com/qshell-darwin-x64-v2.4.2.zip) ## 安装 diff --git a/cmd/root.go b/cmd/root.go index 8dadd62c..11f878da 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -18,7 +18,8 @@ import ( var ( // 开启命令行的调试模式 - DebugFlag bool + DebugFlag bool + DeepDebugInfo bool // qshell 版本信息, qshell -v VersionFlag bool @@ -69,6 +70,7 @@ func init() { cobra.OnInitialize(initConfig) RootCmd.PersistentFlags().BoolVarP(&DebugFlag, "debug", "d", false, "debug mode") + RootCmd.PersistentFlags().BoolVarP(&DeepDebugInfo, "ddebug", "D", false, "deep debug mode") RootCmd.PersistentFlags().BoolVarP(&VersionFlag, "version", "v", false, "show version") RootCmd.PersistentFlags().StringVarP(&cfgFile, "config", "C", "", "config file (default is $HOME/.qshell.json)") RootCmd.PersistentFlags().BoolVarP(&local, "local", "L", false, "use current directory as config file path") @@ -83,10 +85,15 @@ func initConfig() { //set qshell user agent storage.UserAgent = UserAgent() + if DeepDebugInfo { + DebugFlag = true + } //parse command if DebugFlag { logs.SetLevel(logs.LevelDebug) client.TurnOnDebug() + // master 已合并, v7.5.0 分支没包含次参数 // + // client.DeepDebugInfo = DeepDebugInfo } else { logs.SetLevel(logs.LevelInformational) } From d959a76e8f61828f7bde0304c8e83e797bba0e67 Mon Sep 17 00:00:00 2001 From: Sxci Date: Wed, 1 Jul 2020 14:56:21 +0800 Subject: [PATCH 2/2] add -D --- cmd/root.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/root.go b/cmd/root.go index 11f878da..c2d8d9d3 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -92,7 +92,7 @@ func initConfig() { if DebugFlag { logs.SetLevel(logs.LevelDebug) client.TurnOnDebug() - // master 已合并, v7.5.0 分支没包含次参数 // + // master 已合并, v7.5.0 分支没包含次参数,等待 v7.5.1 // client.DeepDebugInfo = DeepDebugInfo } else { logs.SetLevel(logs.LevelInformational)