diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 1a793e9..9b56fe4 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -5,7 +5,7 @@ on: branches: - main tags: - - release-* + - release-*.*.* permissions: contents: write @@ -49,31 +49,27 @@ jobs: if: ${{ matrix.os == 'macos-latest' }} run: cargo build --release --target ${{ matrix.target2 }} --locked - - name: Get latest release version number - id: get_version - uses: battila7/get-version-action@v2 - - name: Create zip file on Windows if: ${{ matrix.os == 'windows-latest' }} run: | choco install zip cd target/${{ matrix.target }}/release - zip fmap-${{ steps.get_version.outputs.version }}-${{ matrix.target }}.zip fmap.exe + zip fmap-0.1.1-${{ matrix.target }}.zip fmap.exe cd ../../.. - name: Create tar.gz file on macOS if: ${{ matrix.os == 'macos-latest' }} run: | chmod +x target/${{ matrix.target }}/release/fmap - tar -zcf target/${{ matrix.target }}/release/fmap-${{ steps.get_version.outputs.version }}-${{ matrix.target }}.tar.gz -C target/${{ matrix.target }}/release fmap + tar -zcf target/${{ matrix.target }}/release/fmap-0.1.1-${{ matrix.target }}.tar.gz -C target/${{ matrix.target }}/release fmap chmod +x target/${{ matrix.target2 }}/release/fmap - tar -zcf target/${{ matrix.target2 }}/release/fmap-${{ steps.get_version.outputs.version }}-${{ matrix.target2 }}.tar.gz -C target/${{ matrix.target2 }}/release fmap + tar -zcf target/${{ matrix.target2 }}/release/fmap-0.1.1-${{ matrix.target2 }}.tar.gz -C target/${{ matrix.target2 }}/release fmap - name: Upload release and assets to GitHub uses: svenstaro/upload-release-action@v2 with: repo_token: ${{ secrets.GITHUB_TOKEN }} tag: ${{ github.ref }} - release_name: fmap ${{ steps.get_version.outputs.version }}-${{ github.run_number }} + release_name: fmap 0.1.1 file_glob: true - file: target/*/release/fmap-${{ steps.get_version.outputs.version }}-*.{zip,tar.gz} + file: target/*/release/fmap-0.1.1-*.{zip,tar.gz}