Add new command reset

[GitHub link #14] [Gitee link #I9V6EV]
This commit is contained in:
Aoran Zeng
2024-06-05 15:07:13 +08:00
parent b2cba6ca27
commit 6efe11a13c
2 changed files with 25 additions and 14 deletions

View File

@@ -87,19 +87,22 @@ get <target> # 查看当前软件的源使用情况
set <target> # 换源,自动测速后挑选最快源
set <target> first # 换源,使用维护团队测速第一的源
set <target> <mirror> # 换源,指定使用某镜像站 (通过list命令查看)
reset <target> # 重置,使用上游默认使用的源
选项:
-ipv6 # 使用IPv6测速
-local # 仅对某项目而非全局换源 (仅部分软件如bundler,pdm支持)
```
当你不想自动测速的时候,你可以直接指定某镜像站。
当你**不想自动测速的时候**,你可以直接指定某镜像站,以及指定维护团队已测试的最快镜像站
```bash
chsrc set ruby # 测速,寻找最快者,换源
# 或
chsrc ls ruby # 列出可用的镜像站
chsrc set ruby rubychina # 使用 RubyChina 作为镜像站
# 或
chsrc set ruby first # 使用维护团队测试的最快镜像站
```
对部分[支持局部换源](https://gitee.com/RubyMetric/chsrc/issues/I9V5I0)的,可以避免全局换源。