Skip to content

Commit 09010c2

Browse files
committed
Notice chsrc-bootstrap in installer.sh
1 parent d656430 commit 09010c2

File tree

2 files changed

+16
-7
lines changed

2 files changed

+16
-7
lines changed

bootstrap/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ end
1010

1111
<br>
1212

13+
14+
1315
## 鸡蛋困境
1416

1517
我们支持预编译的操作系统目前只有 `Windows`, `Linux`, `macOS`,支持的架构请参考[项目 README](../README.md)

tool/installer.sh

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# | DeepSeek <https://chat.deepseek.com/>
1010
# |
1111
# Created On : <2024-10-25>
12-
# Last Modified : <2025-03-25>
12+
# Last Modified : <2025-07-12>
1313
#
1414
# chsrc installer for POSIX (mainly Linux & macOS)
1515
# ---------------------------------------------------------------
@@ -111,6 +111,10 @@ let_user_build() {
111111
fi
112112
}
113113

114+
let_user_use_bootstrap() {
115+
info "请参考: https://github.com/RubyMetric/chsrc/tree/main/bootstrap 查找是否存在已有的 boostrapper"
116+
}
117+
114118

115119
let_user_compile() {
116120
source_zip_url="https://gitee.com/RubyMetric/chsrc/repository/archive/main.zip"
@@ -162,10 +166,11 @@ set_arch() {
162166
armv7*) arch="armv7" ;;
163167
*)
164168
if is_zh; then
165-
warn "抱歉, 暂无预编译二进制文件供您的架构: ${arch} 使用。请自行编译"
169+
warn "抱歉, 暂无预编译二进制文件供您的架构: ${arch} 使用。请使用 chsrc-bootstrap 或 自行编译"
166170
else
167171
warn "Sorry, No precompiled binaries for your arch: ${arch}. Please compile it on your own:"
168172
fi
173+
let_user_use_bootstrap
169174
let_user_compile
170175
exit 1
171176
;;
@@ -182,31 +187,33 @@ set_platform() {
182187
whatos=$(get_os)
183188
if [ "$whatos" = "android" ]; then
184189
if is_zh; then
185-
info "抱歉, 暂无预编译二进制文件供安卓使用。请自行编译:"
190+
info "使用 chsrc-bootstrap: Termux"
186191
else
187-
info "Sorry, No precompiled binaries for Android! Please compile it on your own:"
192+
info "Use chsrc-bootstrap: Termux"
188193
fi
189-
let_user_compile
194+
wget -O - https://gitee.com/RubyMetric/chsrc/raw/main/bootstrap/Termux.bash | bash
190195
exit 1
191196
fi
192197
;;
193198
darwin) platform="macos" ;;
194199
bsd|dragonfly)
195200
platform="bsd"
196201
if is_zh; then
197-
info "抱歉, 暂无预编译二进制文件供BSD使用。请自行编译"
202+
info "抱歉, 暂无预编译二进制文件供BSD使用。请使用 chsrc-bootstrap 或 自行编译"
198203
else
199204
info "Sorry, No precompiled binaries for BSD! Please compile it on your own:"
200205
fi
206+
let_user_use_bootstrap
201207
let_user_compile
202208
exit 1
203209
;;
204210
*)
205211
if is_zh; then
206-
error_exit "抱歉,暂无预编译二进制文件供您的平台: ${platform} 使用。请自行编译"
212+
error_exit "抱歉,暂无预编译二进制文件供您的平台: ${platform} 使用。请使用 chsrc-bootstrap 或 自行编译"
207213
else
208214
error_exit "Sorry, No precompiled binaries for your platform: ${platform}. Please compile it on your own:"
209215
fi
216+
let_user_use_bootstrap
210217
let_user_compile
211218
exit 1
212219
;;

0 commit comments

Comments
 (0)