From 750545c2d05ec9084b2763a5731a9fa43655424d Mon Sep 17 00:00:00 2001 From: nsnail Date: Tue, 13 Dec 2022 11:20:53 +0800 Subject: [PATCH] --- README.md | 18 +++++++++++------ README.zh-CN.md | 26 ++++++++++++++----------- src/Color/Main.cs | 4 +++- src/Color/MouseHook.cs | 5 ++++- src/Color/Option.cs | 4 +++- src/Color/WinInfo.cs | 2 +- src/Color/WinMain.cs | 2 +- src/CsxEditor.cs | 2 +- src/DirOption.cs | 4 +++- src/FilesTool.cs | 13 ++++++++----- src/Get/Main.cs | 8 +++++--- src/Get/Option.cs | 5 ++++- src/Git/Main.cs | 6 ++++-- src/Git/Option.cs | 5 ++++- src/Git/ProgressTaskStateExtensions.cs | 7 +------ src/Git/TaskStatusColumn.cs | 6 +++++- src/Guid/Main.cs | 5 ++++- src/Guid/Option.cs | 7 +++++-- src/IP/Main.cs | 4 +++- src/IP/Option.cs | 4 +++- src/Json/Main.cs | 6 ++++-- src/Json/Option.cs | 5 ++++- src/Lang/Str.tt | 10 +++++----- src/Option.cs | 6 ++++-- src/Program.cs | 2 +- src/Pwd/Main.cs | 4 +++- src/Pwd/Option.cs | 5 ++++- src/Rbom/Main.cs | 5 ++++- src/Rbom/Option.cs | 5 ++++- src/Text/Main.cs | 5 ++++- src/Text/Option.cs | 5 ++++- src/Time/Main.cs | 5 ++++- src/Time/Option.cs | 5 ++++- src/Time/ProgressTaskStateExtensions.cs | 2 +- src/Time/TaskResultColumn.cs | 5 ++++- src/Time/TaskStatusColumn.cs | 7 ++++++- src/ToLf/Main.cs | 8 ++++++-- src/ToLf/Option.cs | 5 ++++- src/ToolBase.cs | 16 +++++++-------- src/ToolsFactory.cs | 24 ----------------------- src/Trim/Main.cs | 6 ++++-- src/Trim/Option.cs | 7 +++++-- src/Win32.cs | 3 +++ 43 files changed, 179 insertions(+), 109 deletions(-) delete mode 100644 src/ToolsFactory.cs diff --git a/README.md b/README.md index d3f6552..81cddf6 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,8 @@ Cross-platform, all-around utility set with a beautiful character interface-the ### Brief introduction -The dot is the one based on the one. NET 7, a cross-platform command-line tool, integrates more than 10 utilities that program developers often use in their daily work, and is constantly increasing. +The dot is the one based on the one. NET 7, a cross-platform command-line tool, integrates more than 10 utilities that +program developers often use in their daily work, and is constantly increasing. ``` USAGE: @@ -33,8 +34,6 @@ COMMANDS: ``` - - ### Some functional examples - ##### Git batch management @@ -56,7 +55,10 @@ dot git -a "config --get http.proxy" d:\repos ![20221212213957](./assets/snapshots/20221212213957.png) - ##### High-precision time-clock synchronization -Supports parallel requests from multiple NTP clock servers, while removing the network communication duration to set the precise synchronization of the native clocks with the NTP standard time: + +Supports parallel requests from multiple NTP clock servers, while removing the network communication duration to set the +precise synchronization of the native clocks with the NTP standard time: + ``` dot time -k ``` @@ -64,25 +66,29 @@ dot time -k ![20221212214514](./assets/snapshots/20221212214514.png) - ##### Text codec + Copy you need to view various codec text in the clipboard, and then enter the following command to view + ``` dot text ``` ![20221212214904](./assets/snapshots/20221212214904.png) - - ##### Multi-threading download tool + Support setting the block size, number of threads to replace the single thread wget tool: + ``` dot get https://github.com/nsnail/dot/releases/download/v1.1.1/dot-v1.1.1-win-x64.7z ``` ![20221212215259](./assets/snapshots/20221212215259.png) - - ##### Remove the blank at the end of the file + Remove excess spaces and line breaks in the tail of all files in the specified directory: + ``` dot trim d:\repos ``` diff --git a/README.zh-CN.md b/README.zh-CN.md index f93e3bf..0fca072 100644 --- a/README.zh-CN.md +++ b/README.zh-CN.md @@ -13,27 +13,25 @@ USAGE: dot [OPTIONS] OPTIONS: - -h, --help Prints help information + -h, --help Prints help information -v, --version Prints version information COMMANDS: - git Git批量操作工具 - color 屏幕坐标颜色选取工具 + git Git批量操作工具 + color 屏幕坐标颜色选取工具 guid GUID工具 ip IP工具 json Json工具 - pwd 随机密码生成器 - rbom 移除文件的uf8 bom + pwd 随机密码生成器 + rbom 移除文件的uf8 bom trim 移除文件尾部换行和空格 text 文本编码工具 time 时间同步工具 - tolf 转换换行符为LF - get 多线程下载工具 + tolf 转换换行符为LF + get 多线程下载工具 ``` - - ### 部分功能示例 - ##### Git批量管理 @@ -55,7 +53,9 @@ dot git -a "config --get http.proxy" d:\repos ![20221212213957](./assets/snapshots/20221212213957.png) - ##### 高精度时钟同步 + 支持多个NTP时钟服务器并行请求,同时除去网络通信时长以设置本机时钟与NTP标准时间精确同步: + ``` dot time -k ``` @@ -63,25 +63,29 @@ dot time -k ![20221212214514](./assets/snapshots/20221212214514.png) - ##### 文本编解码 + 复制你需要查看各种编解码的文本在剪贴板中,然后输入如下命令,即可查看 + ``` dot text ``` ![20221212214904](./assets/snapshots/20221212214904.png) - - ##### 多线程下载工具 + 支持设置分块大小,线程数量,用以替代单线程的wget工具: + ``` dot get https://github.com/nsnail/dot/releases/download/v1.1.1/dot-v1.1.1-win-x64.7z ``` ![20221212215259](./assets/snapshots/20221212215259.png) - - ##### 移除文件末尾空白 + 移除指定目录下所有文件尾部多余的空格和换行符: + ``` dot trim d:\repos ``` diff --git a/src/Color/Main.cs b/src/Color/Main.cs index 5deab3d..889b509 100644 --- a/src/Color/Main.cs +++ b/src/Color/Main.cs @@ -1,9 +1,11 @@ +// ReSharper disable ClassNeverInstantiated.Global + #if NET7_0_WINDOWS namespace Dot.Color; [Description(nameof(Str.ScreenPixelTool))] [Localization(typeof(Str))] -public sealed class Main : ToolBase