diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 36495a5..97b6421 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -22,8 +22,6 @@ jobs: name: Prepare Release if: github.event_name == 'workflow_dispatch' runs-on: ubuntu-latest - outputs: - version: ${{ steps.version.outputs.version }} steps: - uses: actions/checkout@v4 with: @@ -82,41 +80,8 @@ jobs: git tag "v$VERSION" git push origin HEAD:${{ github.ref_name }} --tags - - name: Output version - id: version - run: echo "version=v${{ github.event.inputs.version }}" >> $GITHUB_OUTPUT - - create-release: - name: Create Release - needs: [prepare] - if: always() && needs.prepare.result != 'failure' - runs-on: ubuntu-latest - outputs: - version: ${{ steps.get_version.outputs.version }} - steps: - - uses: actions/checkout@v4 - - name: Get version - id: get_version - run: | - if [ "${{ github.event_name }}" = "workflow_dispatch" ]; then - echo "version=v${{ github.event.inputs.version }}" >> $GITHUB_OUTPUT - else - echo "version=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT - fi - - name: Create Release - uses: softprops/action-gh-release@v2 - with: - tag_name: ${{ steps.get_version.outputs.version }} - name: Release ${{ steps.get_version.outputs.version }} - draft: false - prerelease: false - generate_release_notes: true - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - build: name: Build - ${{ matrix.platform.name }} - needs: create-release runs-on: ${{ matrix.platform.runner }} strategy: fail-fast: false @@ -127,25 +92,25 @@ jobs: runner: windows-latest target: x86_64-pc-windows-msvc binary: ziro.exe - asset: ziro-windows-x86_64.zip + asset: windows-x64.zip - name: Linux x64 os: linux runner: ubuntu-latest target: x86_64-unknown-linux-gnu binary: ziro - asset: ziro-linux-x86_64.zip + asset: linux-x64.zip - name: Linux ARM64 os: linux runner: ubuntu-latest target: aarch64-unknown-linux-gnu binary: ziro - asset: ziro-linux-aarch64.zip + asset: linux-aarch64.zip - name: macOS ARM64 os: macos runner: macos-latest target: aarch64-apple-darwin binary: ziro - asset: ziro-macos-aarch64.zip + asset: macos-aarch64.zip steps: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@1.88.0 @@ -195,7 +160,7 @@ jobs: - name: Upload Release Assets uses: softprops/action-gh-release@v2 with: - tag_name: ${{ needs.create-release.outputs.version }} + tag_name: ${{ github.ref_name }} files: | ${{ matrix.platform.asset }} ${{ matrix.platform.asset }}.sha256 @@ -204,7 +169,7 @@ jobs: publish-crates: name: Publish to crates.io - needs: [create-release, build] + needs: [build] runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 @@ -215,7 +180,7 @@ jobs: publish-npm: name: Publish to npm - needs: [create-release, build] + needs: [build] runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 diff --git a/Cargo.toml b/Cargo.toml index 313979a..cfe68ad 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ziro" -version = "0.0.24" +version = "0.0.26" edition = "2024" authors = ["huangshan"] description = "Cross-platform port management tool - quickly find and kill processes occupying ports" diff --git a/package.json b/package.json index 720f50f..600eccb 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@ithinku/ziro", - "version": "0.0.24", + "version": "0.0.26", "description": "跨平台端口管理工具 - 快速查找和终止占用端口的进程", "main": "bin/ziro.js", "bin": {