All recipes use UpstreamProvider

This commit is contained in:
Aoran Zeng
2025-08-11 03:43:17 +08:00
parent 1be3dc2a0b
commit 24a0aff66d
59 changed files with 274 additions and 277 deletions

View File

@@ -24,7 +24,7 @@ pl_clojure_prelude ()
chef_allow_user_define(this);
def_sources_begin()
{&upstream, NULL, DelegateToUpstream},
{&UpstreamProvider, NULL, DelegateToUpstream},
{&MirrorZ, "https://mirrors.cernet.edu.cn/clojars/", DelegateToMirror},
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/clojars/", DelegateToMirror},
{&Nju, "https://mirror.nju.edu.cn/clojars/", DelegateToMirror},

View File

@@ -26,11 +26,11 @@ pl_dart_flutter_prelude (void)
chef_allow_user_define(this);
def_sources_begin()
{&upstream, "https://storage.googleapis.com", FeedByPrelude},
{&FlutterCN, "https://storage.flutter-io.cn", FeedByPrelude},
{&Sjtug_Zhiyuan, "https://mirror.sjtu.edu.cn", FeedByPrelude }, /* 官方文档也没有给后缀,怀疑是否存在问题 */
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/flutter", FeedByPrelude},
{&Nju, "https://mirror.nju.edu.cn/flutter", FeedByPrelude}
{&UpstreamProvider, "https://storage.googleapis.com", FeedByPrelude},
{&FlutterCN, "https://storage.flutter-io.cn", FeedByPrelude},
{&Sjtug_Zhiyuan, "https://mirror.sjtu.edu.cn", FeedByPrelude }, /* 官方文档也没有给后缀,怀疑是否存在问题 */
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/flutter", FeedByPrelude},
{&Nju, "https://mirror.nju.edu.cn/flutter", FeedByPrelude}
def_sources_end()
chsrc_set_sources_speed_measure_url_with_postfix (this, "/flutter_infra_release/releases/stable/linux/flutter_linux_v1.0.0-stable.tar.xz");

View File

@@ -26,11 +26,11 @@ pl_dart_prelude (void)
chef_allow_user_define(this);
def_sources_begin()
{&upstream, "https://pub.dev", FeedByPrelude},
{&FlutterCN, "https://pub.flutter-io.cn", FeedByPrelude},
{&Sjtug_Zhiyuan, "https://mirror.sjtu.edu.cn/dart-pub", FeedByPrelude},
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/dart-pub", FeedByPrelude},
{&Nju, "https://mirror.nju.edu.cn/dart-pub", FeedByPrelude}
{&UpstreamProvider, "https://pub.dev", FeedByPrelude},
{&FlutterCN, "https://pub.flutter-io.cn", FeedByPrelude},
{&Sjtug_Zhiyuan, "https://mirror.sjtu.edu.cn/dart-pub", FeedByPrelude},
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/dart-pub", FeedByPrelude},
{&Nju, "https://mirror.nju.edu.cn/dart-pub", FeedByPrelude}
def_sources_end()
chsrc_set_sources_speed_measure_url_with_postfix (this, "/packages/flutter_vision/versions/1.1.4.tar.gz");

View File

@@ -41,14 +41,14 @@ pl_go_prelude ()
def_sources_begin()
{&upstream, "https://proxy.golang.org", DelegateToUpstream},
{&GoProxyCN, "https://goproxy.cn", DelegateToMirror},
{&Ali, "https://mirrors.aliyun.com/goproxy/", DelegateToMirror},
{&UpstreamProvider, "https://proxy.golang.org", DelegateToUpstream},
{&GoProxyCN, "https://goproxy.cn", DelegateToMirror},
{&Ali, "https://mirrors.aliyun.com/goproxy/", DelegateToMirror},
// 暂时停用华为镜像源, 详见 https://github.com/RubyMetric/chsrc/issues/227
// {&Huawei, "https://mirrors.huaweicloud.com/goproxy/", DelegateToMirror},
// {&Huawei, "https://mirrors.huaweicloud.com/goproxy/", DelegateToMirror},
{&GoProxyIO, "https://goproxy.io", DelegateToMirror}
{&GoProxyIO, "https://goproxy.io", DelegateToMirror}
def_sources_end()
}

View File

@@ -24,7 +24,7 @@ pl_haskell_prelude ()
chef_allow_user_define(this);
def_sources_begin()
{&upstream, NULL, DelegateToUpstream},
{&UpstreamProvider, NULL, DelegateToUpstream},
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/hackage", DelegateToMirror},
{&Bfsu, "https://mirrors.bfsu.edu.cn/hackage", DelegateToMirror},
{&Nju, "https://mirror.nju.edu.cn/hackage", DelegateToMirror},

View File

@@ -25,7 +25,7 @@ pl_java_prelude ()
chef_allow_user_define(this);
def_sources_begin()
{&upstream, "https://repo1.maven.org/maven2/", DelegateToUpstream},
{&UpstreamProvider, "https://repo1.maven.org/maven2/", DelegateToUpstream},
{&Ali, "https://maven.aliyun.com/repository/public/", DelegateToMirror},
{&Huawei, "https://mirrors.huaweicloud.com/repository/maven/", DelegateToMirror},

View File

@@ -33,10 +33,10 @@ pl_js_group_prelude (void)
chef_allow_user_define(this);
def_sources_begin()
{&upstream, "https://registry.npmjs.org/", FeedByPrelude}, /* @note 根据 pnpm 官网,有最后的斜线 */
{&NpmMirror, "https://registry.npmmirror.com", FeedByPrelude},
{&Huawei, "https://mirrors.huaweicloud.com/repository/npm/", FeedByPrelude},
{&Tencent, "https://mirrors.cloud.tencent.com/npm/", FeedByPrelude}
{&UpstreamProvider, "https://registry.npmjs.org/", FeedByPrelude}, /* @note 根据 pnpm 官网,有最后的斜线 */
{&NpmMirror, "https://registry.npmmirror.com", FeedByPrelude},
{&Huawei, "https://mirrors.huaweicloud.com/repository/npm/", FeedByPrelude},
{&Tencent, "https://mirrors.cloud.tencent.com/npm/", FeedByPrelude}
def_sources_end()
// 29MB 大小
@@ -67,7 +67,7 @@ pl_js_nodejs_binary_prelude (void)
chef_allow_user_define(this);
def_sources_begin()
{&upstream, "https://nodejs.org/dist/", FeedByPrelude},
{&UpstreamProvider, "https://nodejs.org/dist/", FeedByPrelude},
{&NpmMirror, "https://npmmirror.com/mirrors", FeedByPrelude},
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/nodejs-release/",FeedByPrelude},
{&Bfsu, "https://mirrors.bfsu.edu.cn/nodejs-release/",FeedByPrelude},

View File

@@ -24,7 +24,7 @@ pl_julia_prelude ()
chef_allow_user_define(this);
def_sources_begin()
{&upstream, NULL, DelegateToUpstream},
{&UpstreamProvider, NULL, DelegateToUpstream},
{&Pku, "https://mirrors.pku.edu.cn/julia", DelegateToMirror},
{&Nju, "https://mirror.nju.edu.cn/julia", DelegateToMirror},
{&Iscas, "https://mirror.iscas.ac.cn/julia", DelegateToMirror}

View File

@@ -31,7 +31,7 @@ pl_lua_prelude ()
chef_allow_user_define(this);
def_sources_begin()
{&upstream, NULL, DelegateToUpstream},
{&UpstreamProvider, NULL, DelegateToUpstream},
{&Api7, "https://luarocks.cn", DelegateToMirror}
def_sources_end()
}

View File

@@ -24,7 +24,7 @@ pl_nuget_prelude ()
chef_forbid_user_define(this);
def_sources_begin()
{&upstream, "https://www.nuget.org/api/v3/", DelegateToUpstream},
{&UpstreamProvider, "https://www.nuget.org/api/v3/", DelegateToUpstream},
{&Huawei, "https://mirrors.huaweicloud.com/repository/nuget/v3", DelegateToMirror}
def_sources_end()
}

View File

@@ -24,8 +24,8 @@ pl_ocaml_prelude ()
chef_allow_user_define(this);
def_sources_begin()
{&upstream, NULL, DelegateToUpstream},
{&Sjtug_Zhiyuan, "https://mirrors.sjtug.sjtu.edu.cn/git/opam-repository.git", DelegateToMirror}
{&UpstreamProvider, NULL, DelegateToUpstream},
{&Sjtug_Zhiyuan, "https://mirrors.sjtug.sjtu.edu.cn/git/opam-repository.git", DelegateToMirror}
def_sources_end()
}

View File

@@ -24,7 +24,7 @@ pl_php_prelude ()
chef_allow_user_define(this);
def_sources_begin()
{&upstream, NULL, DelegateToUpstream},
{&UpstreamProvider, NULL, DelegateToUpstream},
{&Ali, "https://mirrors.aliyun.com/composer/", DelegateToMirror},
{&Tencent, "https://mirrors.tencent.com/composer/", DelegateToMirror},
// {&Tencent_Intra, "https://mirrors.tencentyun.com/composer/", DelegateToMirror},

View File

@@ -24,7 +24,7 @@ pl_perl_prelude ()
chef_allow_user_define(this);
def_sources_begin()
{&upstream, NULL, DelegateToUpstream},
{&UpstreamProvider, NULL, DelegateToUpstream},
{&Bfsu, "https://mirrors.bfsu.edu.cn/CPAN/", DelegateToMirror},
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/CPAN/", DelegateToMirror},
{&Bjtu, "https://mirror.bjtu.edu.cn/cpan/", DelegateToMirror},

View File

@@ -42,7 +42,7 @@ pl_python_group_prelude (void)
def_sources_begin()
{&upstream, "https://pypi.org/simple", FeedByPrelude},
{&UpstreamProvider, "https://pypi.org/simple", FeedByPrelude},
{&MirrorZ, "https://mirrors.cernet.edu.cn/pypi/web/simple",FeedByPrelude},
{&Bfsu, "https://mirrors.bfsu.edu.cn/pypi/web/simple", FeedByPrelude},
/* 不要添加Zju浙大的PyPI服务在校外访问会自动转向Tuna */

View File

@@ -25,7 +25,7 @@ pl_r_prelude ()
// 以下注释的是不含有bioconductor的镜像站我们在换cran的同时也直接帮助用户换bioconductor
def_sources_begin()
{&upstream, NULL, DelegateToUpstream},
{&UpstreamProvider, NULL, DelegateToUpstream},
{&Sjtug_Zhiyuan, "https://mirrors.sjtug.sjtu.edu.cn/cran/", DelegateToMirror},
// {&Ali, "https://mirrors.aliyun.com/CRAN/", DelegateToMirror},
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/CRAN/", DelegateToMirror},

View File

@@ -31,9 +31,9 @@ pl_ruby_prelude (void)
chef_allow_user_define(this);
def_sources_begin()
{&upstream, "https://rubygems.org", "https://rubygems.org/gems/nokogiri-1.15.0-java.gem"},
{&RubyChina, "https://gems.ruby-china.com/", DelegateToMirror},
{&Ustc, "https://mirrors.ustc.edu.cn/rubygems/", DelegateToMirror}
{&UpstreamProvider, "https://rubygems.org", "https://rubygems.org/gems/nokogiri-1.15.0-java.gem"},
{&RubyChina, "https://gems.ruby-china.com/", DelegateToMirror},
{&Ustc, "https://mirrors.ustc.edu.cn/rubygems/", DelegateToMirror}
// {&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/rubygems/", DelegateToMirror},
// {&Bfsu, "https://mirrors.bfsu.edu.cn/rubygems/", DelegateToMirror},

View File

@@ -28,13 +28,10 @@ pl_rust_cargo_prelude (void)
// 以下都支持稀疏索引,我们换源时都将默认添加 `sparse+`。链接末尾的 `/` 不能缺少
def_sources_begin()
{&upstream, "https://crates.io/", "https://crates.io/api/v1/crates/windows/0.58.0/download"},
{&MirrorZ, "https://mirrors.cernet.edu.cn/crates.io-index/", DelegateToMirror},
{&RsProxyCN, "https://rsproxy.cn/index/", DelegateToMirror},
{&Ali, "https://mirrors.aliyun.com/crates.io-index/",
"https://mirrors.aliyun.com/crates/api/v1/crates/windows/0.58.0/download"},
{&UpstreamProvider, "https://crates.io/", "https://crates.io/api/v1/crates/windows/0.58.0/download"},
{&MirrorZ, "https://mirrors.cernet.edu.cn/crates.io-index/", DelegateToMirror},
{&RsProxyCN, "https://rsproxy.cn/index/", DelegateToMirror},
{&Ali, "https://mirrors.aliyun.com/crates.io-index/", FeedByPrelude},
{&Zju, "https://mirrors.zju.edu.cn/crates.io-index/", DelegateToMirror},
/* 注释原因: (2025-06-17) 镜像同步失败,多数包都不可用 */

View File

@@ -29,16 +29,16 @@ pl_rust_rustup_prelude (void)
chef_allow_user_define(this);
def_sources_begin()
{&upstream, "https://static.rust-lang.org", FeedByPrelude},
{&MirrorZ, "https://mirrors.cernet.edu.cn/rustup", FeedByPrelude},
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/rustup", FeedByPrelude},
{&Ustc, "https://mirrors.ustc.edu.cn/rust-static", FeedByPrelude},
{&Nju, "https://mirror.nju.edu.cn/rustup", FeedByPrelude},
{&Sjtug_Zhiyuan, "https://mirror.sjtu.edu.cn/rust-static", FeedByPrelude},
{&Zju, "https://mirrors.zju.edu.cn/rustup", FeedByPrelude},
{&Iscas, "https://mirror.iscas.ac.cn/rustup", FeedByPrelude},
{&Ali, "https://mirrors.aliyun.com/rustup", FeedByPrelude},
{&RsProxyCN, "https://rsproxy.cn", FeedByPrelude}
{&UpstreamProvider, "https://static.rust-lang.org", FeedByPrelude},
{&MirrorZ, "https://mirrors.cernet.edu.cn/rustup", FeedByPrelude},
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/rustup", FeedByPrelude},
{&Ustc, "https://mirrors.ustc.edu.cn/rust-static", FeedByPrelude},
{&Nju, "https://mirror.nju.edu.cn/rustup", FeedByPrelude},
{&Sjtug_Zhiyuan, "https://mirror.sjtu.edu.cn/rust-static", FeedByPrelude},
{&Zju, "https://mirrors.zju.edu.cn/rustup", FeedByPrelude},
{&Iscas, "https://mirror.iscas.ac.cn/rustup", FeedByPrelude},
{&Ali, "https://mirrors.aliyun.com/rustup", FeedByPrelude},
{&RsProxyCN, "https://rsproxy.cn", FeedByPrelude}
def_sources_end()
// 20MB大小