mirror of
https://github.com/RubyMetric/chsrc
synced 2025-10-20 18:05:08 +08:00
Use chsrc_alert2()
This commit is contained in:
@@ -68,7 +68,7 @@ pl_nodejs_group_setsrc (char *option)
|
||||
"npm, pnpm, yarn. If you need to change the source independently, "
|
||||
"please run independently `chsrc set <pkg-manager>`"
|
||||
: "将同时更换3个包管理器 npm, pnpm, Yarn 的源,若需要独立换源,请独立运行 chsrc set <pkg-manager>";
|
||||
chsrc_note2 (msg);
|
||||
chsrc_alert2 (msg);
|
||||
}
|
||||
|
||||
bool npm_exist, yarn_exist, pnpm_exist;
|
||||
|
@@ -49,8 +49,8 @@ pl_ocaml_setsrc (char *option)
|
||||
|
||||
chsrc_run (cmd, RunOpt_Default);
|
||||
|
||||
chsrc_note2 ("如果是首次使用 opam ,请使用以下命令进行初始化");
|
||||
p(xy_2strjoin ("opam init default ", source.url));
|
||||
chsrc_alert2 ("如果是首次使用 opam ,请使用以下命令进行初始化");
|
||||
println (xy_2strjoin ("opam init default ", source.url));
|
||||
|
||||
chsrc_determine_chgtype (ChgType_SemiAuto);
|
||||
chsrc_conclude (&source);
|
||||
|
@@ -60,7 +60,7 @@ pl_perl_setsrc (char *option)
|
||||
"perl -MCPAN -e \"CPAN::HandleConfig->load(); CPAN::HandleConfig->edit('urllist', 'unshift', '", source.url, "'); CPAN::HandleConfig->commit()\"");
|
||||
chsrc_run (cmd, RunOpt_Default);
|
||||
|
||||
chsrc_note2 ("请使用 perl -v 以及 cpan -v,若 Perl >= v5.36 或 CPAN >= 2.29,请额外手动调用下面的命令");
|
||||
chsrc_alert2 ("请使用 perl -v 以及 cpan -v,若 Perl >= v5.36 或 CPAN >= 2.29,请额外手动调用下面的命令");
|
||||
p ("perl -MCPAN -e \"CPAN::HandleConfig->load(); CPAN::HandleConfig->edit('pushy_https', 0);; CPAN::HandleConfig->commit()\"");
|
||||
|
||||
chsrc_determine_chgtype (ChgType_SemiAuto);
|
||||
|
@@ -15,7 +15,7 @@
|
||||
void
|
||||
pl_python_poetry_getsrc (char *option)
|
||||
{
|
||||
chsrc_note2 ("poetry换源情况: 请查阅本项目 pyproject.toml 中 [[tool.poetry.source]]");
|
||||
chsrc_note2 ("poetry换源情况: 请查看本项目 pyproject.toml 中 [[tool.poetry.source]]");
|
||||
}
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ pl_python_poetry_setsrc (char *option)
|
||||
char *cmd = NULL;
|
||||
|
||||
if (!chsrc_in_local_mode())
|
||||
chsrc_note2 ("Poertry 仅支持项目级换源");
|
||||
chsrc_alert2 ("Poetry 仅支持项目级换源");
|
||||
|
||||
cmd = xy_2strjoin ("poetry source add my_mirror ", source.url);
|
||||
chsrc_run (cmd, RunOpt_No_Last_New_Line);
|
||||
|
@@ -48,7 +48,7 @@ pl_python_group_setsrc (char *option)
|
||||
"pip, Poetry, PDM. If you need to change the source independently, "
|
||||
"please run independently `chsrc set <pkg-manager>`"
|
||||
: "将同时更换4个包管理器 pip, Poetry, PDM, uv 的源,若需要独立换源,请独立运行 chsrc set <pkg-manager>";
|
||||
chsrc_note2 (msg);
|
||||
chsrc_alert2 (msg);
|
||||
}
|
||||
|
||||
bool pdm_exist = false,
|
||||
|
@@ -96,7 +96,7 @@ pl_rust_rustup_setsrc (char *option)
|
||||
|
||||
chsrc_determine_chgtype (ChgType_Auto);
|
||||
chsrc_conclude (&source);
|
||||
chsrc_note2 ("请重启终端使rustup环境变量生效");
|
||||
chsrc_alert2 ("请重启终端使rustup环境变量生效");
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user