This commit is contained in:
sanchuanhehe 2025-06-14 21:20:26 +08:00
commit a67fc7c859
6 changed files with 18 additions and 12 deletions

View File

@ -1,5 +1,5 @@
<div align="center">
<img alt="chsrc logo" src="image/chsrc.png"/>
<img alt="chsrc logo" src="doc/image/chsrc.png"/>
</div>
全平台通用换源工具与框架 `chsrc`**目标支持 Linux, Windows (MSYS2, Cygwin), macOS, BSD 等尽可能多的操作系统环境龙芯、飞腾、RISC-V 等尽可能多的 CPU**。
@ -39,9 +39,11 @@
可参与的任务与挑战:
1. [提供默认源地址如Maven等的默认源URL帮助我们进行 `chsrc reset`](https://github.com/RubyMetric/chsrc/issues/111)
1. [Shell auto-completion 终端命令自动补全](https://github.com/RubyMetric/chsrc/issues/204)
2. [CentOS (Stream) Recipe](https://github.com/RubyMetric/chsrc/issues/48)
2. [搜集默认源地址,帮助使用 `reset` 功能](https://github.com/RubyMetric/chsrc/issues/111)
3. [搜集测速地址,帮助使用 `measure` 功能](https://github.com/RubyMetric/chsrc/issues/205)
<br>
@ -84,7 +86,7 @@
## 📌 示例
<div align="center">
<img alt="chsrc set node" src="image/example-set-nodejs.png"/>
<img alt="chsrc set node" src="doc/image/example-set-nodejs.png"/>
</div>
<br>

View File

Before

Width:  |  Height:  |  Size: 40 KiB

After

Width:  |  Height:  |  Size: 40 KiB

View File

Before

Width:  |  Height:  |  Size: 107 KiB

After

Width:  |  Height:  |  Size: 107 KiB

View File

Before

Width:  |  Height:  |  Size: 143 KiB

After

Width:  |  Height:  |  Size: 143 KiB

View File

Before

Width:  |  Height:  |  Size: 128 KiB

After

Width:  |  Height:  |  Size: 128 KiB

View File

@ -7,7 +7,7 @@
* |
* Created On : <2023-09-03>
* Major Revision : 1
* Last Modified : <2024-12-11>
* Last Modified : <2025-06-12>
* ------------------------------------------------------------*/
static SourceProvider_t pl_python_pypi_upstream =
@ -17,12 +17,13 @@ static SourceProvider_t pl_python_pypi_upstream =
};
/**
* @update 2024-12-08
* @note Zjupypi在校外访问会自动转向Tuna
* @update 2025-06-12
* @note ZjuPyPI服务在校外访问会自动转向Tuna
*/
static Source_t pl_python_sources[] =
{
{&pl_python_pypi_upstream , "https://pypi.org/simple"},
{&pl_python_pypi_upstream, "https://pypi.org/simple"},
{&MirrorZ, "https://mirrors.cernet.edu.cn/pypi/web/simple"},
{&Bfsu, "https://mirrors.bfsu.edu.cn/pypi/web/simple"},
{&Lzuoss, "https://mirror.lzu.edu.cn/pypi/web/simple"},
{&Jlu, "https://mirrors.jlu.edu.cn/pypi/web/simple"},
@ -58,15 +59,18 @@ pl_python_get_py_program_name (char **prog_name)
bool py_exist = false;
// 由于Python2和Python3的历史目前2024-06许多python命令实际上仍然是python2
// https://gitee.com/RubyMetric/chsrc/issues/I9VZL2
// 因此我们首先测试 python3
/**
* @issue https://gitee.com/RubyMetric/chsrc/issues/I9VZL2
*
* Python2和Python3的历史2024-06python命令实际上仍然是python2
* python3
*/
py_exist = chsrc_check_program ("python3");
if (py_exist) *prog_name = "python3";
else
{
// 不要调用 python 自己,而是使用 python --version避免Windows弹出Microsoft Store
/* 不要调用 python 自己,而是使用 python --version避免Windows弹出Microsoft Store */
py_exist = chsrc_check_program ("python");
if (py_exist) *prog_name = "python";