Skip to content

Commit 24a0aff

Browse files
committed
All recipes use UpstreamProvider
1 parent 1be3dc2 commit 24a0aff

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+274
-277
lines changed

src/framework/struct.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ TargetRegisterInfo_t;
172172
#define use_this(t) Target_t *this = &t##_target;
173173
#define use_this_source(t) use_this(t); Source_t source = chsrc_yield_source_and_confirm (this, option);
174174

175-
#define def_sources_begin() SourceProvider_t upstream = UpstreamProvider; Source_t sources[] = {
175+
#define def_sources_begin() Source_t sources[] = {
176176
#define def_sources_end() }; \
177177
this->sources_n = xy_arylen(sources); \
178178
char *_sources_storage = xy_malloc0 (sizeof(sources)); \

src/recipe/lang/Clojure.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ pl_clojure_prelude ()
2424
chef_allow_user_define(this);
2525

2626
def_sources_begin()
27-
{&upstream, NULL, DelegateToUpstream},
27+
{&UpstreamProvider, NULL, DelegateToUpstream},
2828
{&MirrorZ, "https://mirrors.cernet.edu.cn/clojars/", DelegateToMirror},
2929
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/clojars/", DelegateToMirror},
3030
{&Nju, "https://mirror.nju.edu.cn/clojars/", DelegateToMirror},

src/recipe/lang/Dart/Flutter.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@ pl_dart_flutter_prelude (void)
2626
chef_allow_user_define(this);
2727

2828
def_sources_begin()
29-
{&upstream, "https://storage.googleapis.com", FeedByPrelude},
30-
{&FlutterCN, "https://storage.flutter-io.cn", FeedByPrelude},
31-
{&Sjtug_Zhiyuan, "https://mirror.sjtu.edu.cn", FeedByPrelude }, /* 官方文档也没有给后缀,怀疑是否存在问题 */
32-
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/flutter", FeedByPrelude},
33-
{&Nju, "https://mirror.nju.edu.cn/flutter", FeedByPrelude}
29+
{&UpstreamProvider, "https://storage.googleapis.com", FeedByPrelude},
30+
{&FlutterCN, "https://storage.flutter-io.cn", FeedByPrelude},
31+
{&Sjtug_Zhiyuan, "https://mirror.sjtu.edu.cn", FeedByPrelude }, /* 官方文档也没有给后缀,怀疑是否存在问题 */
32+
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/flutter", FeedByPrelude},
33+
{&Nju, "https://mirror.nju.edu.cn/flutter", FeedByPrelude}
3434
def_sources_end()
3535

3636
chsrc_set_sources_speed_measure_url_with_postfix (this, "/flutter_infra_release/releases/stable/linux/flutter_linux_v1.0.0-stable.tar.xz");

src/recipe/lang/Dart/Pub.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@ pl_dart_prelude (void)
2626
chef_allow_user_define(this);
2727

2828
def_sources_begin()
29-
{&upstream, "https://pub.dev", FeedByPrelude},
30-
{&FlutterCN, "https://pub.flutter-io.cn", FeedByPrelude},
31-
{&Sjtug_Zhiyuan, "https://mirror.sjtu.edu.cn/dart-pub", FeedByPrelude},
32-
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/dart-pub", FeedByPrelude},
33-
{&Nju, "https://mirror.nju.edu.cn/dart-pub", FeedByPrelude}
29+
{&UpstreamProvider, "https://pub.dev", FeedByPrelude},
30+
{&FlutterCN, "https://pub.flutter-io.cn", FeedByPrelude},
31+
{&Sjtug_Zhiyuan, "https://mirror.sjtu.edu.cn/dart-pub", FeedByPrelude},
32+
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/dart-pub", FeedByPrelude},
33+
{&Nju, "https://mirror.nju.edu.cn/dart-pub", FeedByPrelude}
3434
def_sources_end()
3535

3636
chsrc_set_sources_speed_measure_url_with_postfix (this, "/packages/flutter_vision/versions/1.1.4.tar.gz");

src/recipe/lang/Go.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -41,14 +41,14 @@ pl_go_prelude ()
4141

4242

4343
def_sources_begin()
44-
{&upstream, "https://proxy.golang.org", DelegateToUpstream},
45-
{&GoProxyCN, "https://goproxy.cn", DelegateToMirror},
46-
{&Ali, "https://mirrors.aliyun.com/goproxy/", DelegateToMirror},
44+
{&UpstreamProvider, "https://proxy.golang.org", DelegateToUpstream},
45+
{&GoProxyCN, "https://goproxy.cn", DelegateToMirror},
46+
{&Ali, "https://mirrors.aliyun.com/goproxy/", DelegateToMirror},
4747

4848
// 暂时停用华为镜像源, 详见 https://github.com/RubyMetric/chsrc/issues/227
49-
// {&Huawei, "https://mirrors.huaweicloud.com/goproxy/", DelegateToMirror},
49+
// {&Huawei, "https://mirrors.huaweicloud.com/goproxy/", DelegateToMirror},
5050

51-
{&GoProxyIO, "https://goproxy.io", DelegateToMirror}
51+
{&GoProxyIO, "https://goproxy.io", DelegateToMirror}
5252
def_sources_end()
5353
}
5454

src/recipe/lang/Haskell.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ pl_haskell_prelude ()
2424
chef_allow_user_define(this);
2525

2626
def_sources_begin()
27-
{&upstream, NULL, DelegateToUpstream},
27+
{&UpstreamProvider, NULL, DelegateToUpstream},
2828
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/hackage", DelegateToMirror},
2929
{&Bfsu, "https://mirrors.bfsu.edu.cn/hackage", DelegateToMirror},
3030
{&Nju, "https://mirror.nju.edu.cn/hackage", DelegateToMirror},

src/recipe/lang/Java.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ pl_java_prelude ()
2525
chef_allow_user_define(this);
2626

2727
def_sources_begin()
28-
{&upstream, "https://repo1.maven.org/maven2/", DelegateToUpstream},
28+
{&UpstreamProvider, "https://repo1.maven.org/maven2/", DelegateToUpstream},
2929
{&Ali, "https://maven.aliyun.com/repository/public/", DelegateToMirror},
3030
{&Huawei, "https://mirrors.huaweicloud.com/repository/maven/", DelegateToMirror},
3131

src/recipe/lang/JavaScript/common.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,10 +33,10 @@ pl_js_group_prelude (void)
3333
chef_allow_user_define(this);
3434

3535
def_sources_begin()
36-
{&upstream, "https://registry.npmjs.org/", FeedByPrelude}, /* @note 根据 pnpm 官网,有最后的斜线 */
37-
{&NpmMirror, "https://registry.npmmirror.com", FeedByPrelude},
38-
{&Huawei, "https://mirrors.huaweicloud.com/repository/npm/", FeedByPrelude},
39-
{&Tencent, "https://mirrors.cloud.tencent.com/npm/", FeedByPrelude}
36+
{&UpstreamProvider, "https://registry.npmjs.org/", FeedByPrelude}, /* @note 根据 pnpm 官网,有最后的斜线 */
37+
{&NpmMirror, "https://registry.npmmirror.com", FeedByPrelude},
38+
{&Huawei, "https://mirrors.huaweicloud.com/repository/npm/", FeedByPrelude},
39+
{&Tencent, "https://mirrors.cloud.tencent.com/npm/", FeedByPrelude}
4040
def_sources_end()
4141

4242
// 29MB 大小
@@ -67,7 +67,7 @@ pl_js_nodejs_binary_prelude (void)
6767
chef_allow_user_define(this);
6868

6969
def_sources_begin()
70-
{&upstream, "https://nodejs.org/dist/", FeedByPrelude},
70+
{&UpstreamProvider, "https://nodejs.org/dist/", FeedByPrelude},
7171
{&NpmMirror, "https://npmmirror.com/mirrors", FeedByPrelude},
7272
{&Tuna, "https://mirrors.tuna.tsinghua.edu.cn/nodejs-release/",FeedByPrelude},
7373
{&Bfsu, "https://mirrors.bfsu.edu.cn/nodejs-release/",FeedByPrelude},

src/recipe/lang/Julia.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ pl_julia_prelude ()
2424
chef_allow_user_define(this);
2525

2626
def_sources_begin()
27-
{&upstream, NULL, DelegateToUpstream},
27+
{&UpstreamProvider, NULL, DelegateToUpstream},
2828
{&Pku, "https://mirrors.pku.edu.cn/julia", DelegateToMirror},
2929
{&Nju, "https://mirror.nju.edu.cn/julia", DelegateToMirror},
3030
{&Iscas, "https://mirror.iscas.ac.cn/julia", DelegateToMirror}

src/recipe/lang/Lua.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ pl_lua_prelude ()
3131
chef_allow_user_define(this);
3232

3333
def_sources_begin()
34-
{&upstream, NULL, DelegateToUpstream},
34+
{&UpstreamProvider, NULL, DelegateToUpstream},
3535
{&Api7, "https://luarocks.cn", DelegateToMirror}
3636
def_sources_end()
3737
}

0 commit comments

Comments
 (0)