diff --git a/include/source.h b/include/source.h index 3453442..74437df 100644 --- a/include/source.h +++ b/include/source.h @@ -6,7 +6,7 @@ * Contributors : Shengwei Chen <414685209@qq.com> * | * Created On : <2023-08-29> - * Last Modified : <2024-11-04> + * Last Modified : <2024-11-08> * * 通用镜像站与换源信息 * ------------------------------------------------------------*/ @@ -173,7 +173,7 @@ typedef struct FeatInfo_t { bool can_user_define; // 用户自定义换源URL enum Capability cap_locally; - char *locally; + char *cap_locally_explain; char *note; } FeatInfo; diff --git a/src/chsrc-main.c b/src/chsrc-main.c index bcb9a6b..9372dc1 100644 --- a/src/chsrc-main.c +++ b/src/chsrc-main.c @@ -364,7 +364,7 @@ cli_print_target_features (FeatInfo f, const char *input_target_name) printf (" %s%s\n", bdgreen(YesMark), purple(locally_msg));br(); break; case PartiallyCan: - printf (" %s%s\n\n %s\n", bdgreen(SemiYesMark), purple(locally_msg), f.locally);br(); + printf (" %s%s\n\n %s\n", bdgreen(SemiYesMark), purple(locally_msg), f.cap_locally_explain);br(); break; default: xy_unreach; diff --git a/src/recipe/lang/Dart/Flutter.c b/src/recipe/lang/Dart/Flutter.c index 7f8387c..e41796a 100644 --- a/src/recipe/lang/Dart/Flutter.c +++ b/src/recipe/lang/Dart/Flutter.c @@ -106,7 +106,7 @@ pl_dart_flutter_feat (char *option) f.can_reset = true; f.cap_locally = CanNot; - f.locally = NULL; + f.cap_locally_explain = NULL; f.can_english = true; f.can_user_define = true; diff --git a/src/recipe/lang/Dart/Pub.c b/src/recipe/lang/Dart/Pub.c index 3dfad38..3568133 100644 --- a/src/recipe/lang/Dart/Pub.c +++ b/src/recipe/lang/Dart/Pub.c @@ -99,7 +99,7 @@ pl_dart_feat (char *option) f.can_reset = true; f.cap_locally = CanNot; - f.locally = NULL; + f.cap_locally_explain = NULL; f.can_english = true; f.can_user_define = true; diff --git a/src/recipe/lang/Go.c b/src/recipe/lang/Go.c index 6b2c247..08c7c9a 100644 --- a/src/recipe/lang/Go.c +++ b/src/recipe/lang/Go.c @@ -95,7 +95,7 @@ pl_go_feat (char *option) f.can_reset = true; f.cap_locally = CanNot; - f.locally = NULL; + f.cap_locally_explain = NULL; f.can_english = false; f.can_user_define = true; diff --git a/src/recipe/lang/Node.js/Bun.c b/src/recipe/lang/Node.js/Bun.c index 7265643..6eff854 100644 --- a/src/recipe/lang/Node.js/Bun.c +++ b/src/recipe/lang/Node.js/Bun.c @@ -71,7 +71,7 @@ pl_nodejs_bun_feat (char *option) f.can_reset = true; f.cap_locally = FullyCan; - f.locally = NULL; + f.cap_locally_explain = NULL; f.can_english = true; f.can_user_define = true; diff --git a/src/recipe/lang/Node.js/Node.js.c b/src/recipe/lang/Node.js/Node.js.c index 96834cb..c85f945 100644 --- a/src/recipe/lang/Node.js/Node.js.c +++ b/src/recipe/lang/Node.js/Node.js.c @@ -3,9 +3,10 @@ * ------------------------------------------------------------- * File Authors : Aoran Zeng * Contributors : Mr. Will + * | * Created On : <2023-08-30> * Major Revision : 2 - * Last Modified : <2024-09-13> + * Last Modified : <2024-11-08> * ------------------------------------------------------------*/ void @@ -64,9 +65,9 @@ pl_nodejs_setsrc (char *option) { { char *msg = CliOpt_InEnglish ? "Three package managers will be replaced for you at the same time: " \ - "npm, pnpm, yarn. If you need to change the source independently, " \ - "please run independently `chsrc set `" - : "将同时为您更换3个包管理器 npm, pnpm, Yarn 的源,若需要独立换源,请独立运行 chsrc set "; + "npm, pnpm, yarn. If you need to change the source independently, " \ + "please run independently `chsrc set `" + : "将同时为您更换3个包管理器 npm, pnpm, Yarn 的源,若需要独立换源,请独立运行 chsrc set "; chsrc_note2 (msg); } @@ -119,7 +120,7 @@ pl_nodejs_feat (char *option) f.can_reset = true; f.cap_locally = FullyCan; - f.locally = "Support npm (chsrc v0.1.7)\nSupport yarn v2 (chsrc v0.1.8.1)\nSupport pnpm (chsrc v0.1.8.2)"; + f.cap_locally_explain = "Support `npm` & `yarn v2` & `pnpm`. No support for `yarn v1`"; f.can_english = true; f.can_user_define = true; diff --git a/src/recipe/lang/Node.js/Yarn.c b/src/recipe/lang/Node.js/Yarn.c index bb50b01..d49ee45 100644 --- a/src/recipe/lang/Node.js/Yarn.c +++ b/src/recipe/lang/Node.js/Yarn.c @@ -98,7 +98,7 @@ pl_nodejs_yarn_feat (char *option) f.can_reset = true; f.cap_locally = FullyCan; - f.locally = NULL; + f.cap_locally_explain = NULL; f.can_english = true; f.can_user_define = true; diff --git a/src/recipe/lang/Node.js/npm.c b/src/recipe/lang/Node.js/npm.c index 96b66f0..f287dca 100644 --- a/src/recipe/lang/Node.js/npm.c +++ b/src/recipe/lang/Node.js/npm.c @@ -67,7 +67,7 @@ pl_nodejs_npm_feat (char *option) f.can_reset = true; f.cap_locally = FullyCan; - f.locally = NULL; + f.cap_locally_explain = NULL; f.can_english = true; f.can_user_define = true; diff --git a/src/recipe/lang/Node.js/nvm.c b/src/recipe/lang/Node.js/nvm.c index 56b733e..aa662bb 100644 --- a/src/recipe/lang/Node.js/nvm.c +++ b/src/recipe/lang/Node.js/nvm.c @@ -70,7 +70,7 @@ pl_nodejs_nvm_feat (char *option) f.can_reset = false; f.cap_locally = CanNot; - f.locally = ""; + f.cap_locally_explain = ""; f.can_english = false; f.can_user_define = true; diff --git a/src/recipe/lang/Node.js/pnpm.c b/src/recipe/lang/Node.js/pnpm.c index 925386a..d077c0e 100644 --- a/src/recipe/lang/Node.js/pnpm.c +++ b/src/recipe/lang/Node.js/pnpm.c @@ -68,7 +68,7 @@ pl_nodejs_pnpm_feat (char *option) f.can_reset = true; f.cap_locally = FullyCan; - f.locally = NULL; + f.cap_locally_explain = NULL; f.can_english = true; f.can_user_define = true; diff --git a/src/recipe/lang/PHP.c b/src/recipe/lang/PHP.c index 2e807b0..3d8300c 100644 --- a/src/recipe/lang/PHP.c +++ b/src/recipe/lang/PHP.c @@ -70,7 +70,7 @@ pl_php_feat (char *option) f.can_reset = false; f.cap_locally = FullyCan; - f.locally = "composer 支持 (From v0.1.7)"; + f.cap_locally_explain = "Support `composer`"; f.can_english = false; f.can_user_define = true; diff --git a/src/recipe/lang/Python/PDM.c b/src/recipe/lang/Python/PDM.c index 70183df..f13cad7 100644 --- a/src/recipe/lang/Python/PDM.c +++ b/src/recipe/lang/Python/PDM.c @@ -70,7 +70,7 @@ pl_python_pdm_feat (char *option) // PDM 完全支持项目级换源 f.cap_locally = FullyCan; - f.locally = NULL; + f.cap_locally_explain = NULL; f.can_english = true; f.can_user_define = true; diff --git a/src/recipe/lang/Python/Poetry.c b/src/recipe/lang/Python/Poetry.c index 08d3864..7dcca7f 100644 --- a/src/recipe/lang/Python/Poetry.c +++ b/src/recipe/lang/Python/Poetry.c @@ -67,7 +67,7 @@ pl_python_poetry_feat (char *option) f.can_reset = true; f.cap_locally = FullyCan; - f.locally = NULL; + f.cap_locally_explain = NULL; f.can_english = false; f.can_user_define = true; diff --git a/src/recipe/lang/Python/Python.c b/src/recipe/lang/Python/Python.c index 9ed76c8..e2dc732 100644 --- a/src/recipe/lang/Python/Python.c +++ b/src/recipe/lang/Python/Python.c @@ -4,7 +4,7 @@ * File Authors : Aoran Zeng * Contributors : Nil Null * Created On : <2023-09-03> - * Last Modified : <2024-09-13> + * Last Modified : <2024-11-08> * * 2024-08-08: uv 似乎暂时没有实现换源 * ------------------------------------------------------------*/ @@ -90,7 +90,7 @@ pl_python_feat (char *option) f.can_reset = true; f.cap_locally = PartiallyCan; - f.locally = "pip 不支持,其他支持"; + f.cap_locally_explain = "Support `Poetry` & `PDM`. No support for `pip`"; f.can_english = false; f.can_user_define = true; diff --git a/src/recipe/lang/Python/pip.c b/src/recipe/lang/Python/pip.c index 73d07ba..86f287e 100644 --- a/src/recipe/lang/Python/pip.c +++ b/src/recipe/lang/Python/pip.c @@ -80,7 +80,7 @@ pl_python_pip_feat (char *option) // pip 不支持项目级换源 f.cap_locally = CanNot; - f.locally = NULL; + f.cap_locally_explain = NULL; f.can_english = true; f.can_user_define = true; diff --git a/src/recipe/lang/Ruby.c b/src/recipe/lang/Ruby.c index 1542607..bace5b7 100644 --- a/src/recipe/lang/Ruby.c +++ b/src/recipe/lang/Ruby.c @@ -4,7 +4,7 @@ * File Authors : Aoran Zeng * Contributors : Nil Null * Created On : <2023-08-29> - * Last Modified : <2024-09-04> + * Last Modified : <2024-11-08> * ------------------------------------------------------------*/ static MirrorSite @@ -104,8 +104,8 @@ pl_ruby_feat (char *option) f.can_reset = true; f.cap_locally = PartiallyCan; - f.locally = "gem 不支持; bundler 支持 (From v0.1.6)"; - f.can_english = false; + f.cap_locally_explain = "Support `bundler`. No support for `gem`"; + f.can_english = true; f.can_user_define = true; f.note = NULL; diff --git a/src/recipe/lang/Rust/Cargo.c b/src/recipe/lang/Rust/Cargo.c index 3b63432..565c406 100644 --- a/src/recipe/lang/Rust/Cargo.c +++ b/src/recipe/lang/Rust/Cargo.c @@ -79,7 +79,7 @@ pl_rust_cargo_feat (char *option) f.can_reset = true; f.cap_locally = PartiallyCan; - f.locally = "可以基于本项目换源吗?请帮助确认"; + f.cap_locally_explain = "可以基于本项目换源吗?请帮助确认"; f.can_english = false; f.can_user_define = true; diff --git a/src/recipe/lang/Rust/rustup.c b/src/recipe/lang/Rust/rustup.c index ca135a9..f87b507 100644 --- a/src/recipe/lang/Rust/rustup.c +++ b/src/recipe/lang/Rust/rustup.c @@ -106,7 +106,7 @@ pl_rust_rustup_feat (char *option) f.can_reset = false; f.cap_locally = CanNot; - f.locally = ""; + f.cap_locally_explain = ""; f.can_english = false; f.can_user_define = true; diff --git a/src/recipe/os/APT/Debian.c b/src/recipe/os/APT/Debian.c index d05fec7..f7e4879 100644 --- a/src/recipe/os/APT/Debian.c +++ b/src/recipe/os/APT/Debian.c @@ -116,7 +116,7 @@ os_debian_feat (char *option) f.can_reset = false; f.cap_locally = CanNot; - f.locally = NULL; + f.cap_locally_explain = NULL; f.can_english = false; f.can_user_define = true; diff --git a/src/recipe/os/APT/Ubuntu.c b/src/recipe/os/APT/Ubuntu.c index d9700e0..554af5a 100644 --- a/src/recipe/os/APT/Ubuntu.c +++ b/src/recipe/os/APT/Ubuntu.c @@ -137,7 +137,7 @@ os_ubuntu_feat (char *option) f.can_reset = true; f.cap_locally = CanNot; - f.locally = NULL; + f.cap_locally_explain = NULL; f.can_english = true; f.can_user_define = true; diff --git a/src/recipe/template.c b/src/recipe/template.c index eabc223..b64c2e0 100644 --- a/src/recipe/template.c +++ b/src/recipe/template.c @@ -112,7 +112,7 @@ FeatInfo f.can_reset = false; f.cap_locally = PartiallyCan; - f.locally = "具体说明是否支持项目级换源..."; + f.cap_locally_explain = "具体说明是否支持项目级换源..."; f.can_english = false; f.can_user_define = false; diff --git a/src/recipe/ware/Docker-Hub.c b/src/recipe/ware/Docker-Hub.c index eda66b4..f41706b 100644 --- a/src/recipe/ware/Docker-Hub.c +++ b/src/recipe/ware/Docker-Hub.c @@ -157,7 +157,7 @@ wr_dockerhub_feat (char *option) f.can_reset = false; f.cap_locally = CanNot; - f.locally = NULL; + f.cap_locally_explain = NULL; f.can_english = false; f.can_user_define = true; diff --git a/src/recipe/ware/Homebrew.c b/src/recipe/ware/Homebrew.c index f72faf0..0d813c5 100644 --- a/src/recipe/ware/Homebrew.c +++ b/src/recipe/ware/Homebrew.c @@ -103,7 +103,7 @@ wr_homebrew_feat (char *option) f.can_reset = false; f.cap_locally = CanNot; - f.locally = NULL; + f.cap_locally_explain = NULL; f.can_english = true; /* 该换源方案中,URL存在拼凑,因此不能让用户手动使用某URL来换源 */