diff --git a/.github/workflows/cross-build.yml b/.github/workflows/cross-build.yml index abae8cc..b5d4f14 100644 --- a/.github/workflows/cross-build.yml +++ b/.github/workflows/cross-build.yml @@ -5,7 +5,7 @@ on: version: description: 'Version number' required: true - default: '7.0.0-beta-6' + default: '7.1.0' dryRun: description: '测试写这个为 true' required: true @@ -89,6 +89,16 @@ jobs: scoop install main/mingw scoop install main/nodejs ${{ matrix.platform.setup }} + - name: Change Version Windows + if: ${{ matrix.platform.name == 'Windows' }} + run: | + (Get-Content -Path .\Cargo.toml -Raw) -replace 'version\s*=\s*".*?"', "version = `"${{inputs.version}}`"" | + Set-Content -Path .\Cargo.toml + shell: pwsh + - name: Change Version Linux + if: ${{ matrix.platform.name != 'linux' }} + run: | + sed -i '' 's/^version = \"[^\"]*\"/version = "${{inputs.version}}"/' Cargo.toml - name: Setup Linux Environment if: ${{ runner.os == 'Linux' }} run: | @@ -170,7 +180,9 @@ jobs: sudo apt update sudo apt upgrade sudo apt install -y llvm clang pkg-config libssl-dev protobuf-compiler - + - name: Change Version Linux + run: | + sed -i '' 's/^version = \"[^\"]*\"/version = "${{inputs.version}}"/' Cargo.toml - name: Setup WASI Environment working-directory: . run: | diff --git a/Cargo.lock b/Cargo.lock index b229c6e..a778aa1 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -541,7 +541,7 @@ dependencies = [ [[package]] name = "cn-font-split" -version = "7.0.0" +version = "7.1.0" dependencies = [ "chrono", "clap 4.5.23", diff --git a/Cargo.toml b/Cargo.toml index 32abda4..129bc1b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "cn-font-split" 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." -version = "7.0.0" +version = "7.1.0" edition = "2021" authors = ["KonghaYao<3446798488@qq.com>"] homepage = "https://chinese-font.netlify.app/"