Skip to content

Commit

Permalink
fix: 修复重定向的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
KonghaYao committed Jan 2, 2025
1 parent 66bf61a commit cd48ca9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion packages/ffi-js/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cn-font-split",
"version": "7.1.5",
"version": "7.1.7",
"description": "划时代的字体切割工具,CJK与任何字符!支持 otf、ttf、woff2 字体多线程切割,完美地细颗粒度地进行包大小控制。A revolutionary font subetter that supports CJK and any characters! It enables multi-threaded subset of otf, ttf, and woff2 fonts, allowing for precise control over package size.",
"main": "./dist/node/index.js",
"module": "./dist/node/index.mjs",
Expand Down
6 changes: 3 additions & 3 deletions packages/ffi-js/scripts/init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ echo "[Info] $rust_target"

function getLatestVersion() {
# 使用 curl 获取最新版本的 JSON 数据
response=$(curl -s https://ungh.cc/repos/KonghaYao/cn-font-split/releases/latest)
response=$(curl -sL https://ungh.cc/repos/KonghaYao/cn-font-split/releases/latest)

# 使用 grep 和 sed 解析出 "tag" 的值
version=$(echo "$response" | grep -o '"tag":"[^"]*"' | sed 's/"tag":"\([^"]*\)"/\1/')
Expand All @@ -85,7 +85,7 @@ function getLatestVersion() {
}

function getAllVersion() {
response=$(curl -s https://ungh.cc/repos/KonghaYao/cn-font-split/releases)
response=$(curl -sL https://ungh.cc/repos/KonghaYao/cn-font-split/releases)
# 使用 grep 和 sed 解析出 "tag" 的值
# 输出版本号
colorEcho BLUE "All versions: "
Expand Down Expand Up @@ -133,7 +133,7 @@ function cn_i() {
local download_url="$GH_HOST/KonghaYao/cn-font-split/releases/download/$version/libffi-$p.$ext"
echo $download_url

curl -fsS -o "$SCRIPT_DIR/libffi-$p.$ext" "$download_url"
curl -fsSL -o "$SCRIPT_DIR/libffi-$p.$ext" "$download_url"

# 检查 version 文件是否存在
if [ -f "$VERSION_FILE" ]; then
Expand Down

0 comments on commit cd48ca9

Please sign in to comment.