chore: Update Cargo.lock for v0.2.3 #9
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Release | |
| on: | |
| push: | |
| tags: | |
| - 'v*' | |
| env: | |
| CARGO_TERM_COLOR: always | |
| jobs: | |
| create-release: | |
| name: Create Release | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| outputs: | |
| upload_url: ${{ steps.create_release.outputs.upload_url }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Create Release | |
| id: create_release | |
| uses: softprops/action-gh-release@v1 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| with: | |
| tag_name: ${{ github.ref_name }} | |
| name: Release ${{ github.ref_name }} | |
| body: | | |
| Changes in this Release | |
| - First Change | |
| - Second Change | |
| draft: false | |
| prerelease: false | |
| build-and-upload: | |
| name: Build and Upload | |
| runs-on: ${{ matrix.os }} | |
| permissions: | |
| contents: write | |
| strategy: | |
| matrix: | |
| include: | |
| - os: ubuntu-latest | |
| target: x86_64-unknown-linux-gnu | |
| binary_name: kilar | |
| - os: ubuntu-latest | |
| target: aarch64-unknown-linux-gnu | |
| binary_name: kilar | |
| - os: macos-latest | |
| target: x86_64-apple-darwin | |
| binary_name: kilar | |
| - os: macos-latest | |
| target: aarch64-apple-darwin | |
| binary_name: kilar | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| targets: ${{ matrix.target }} | |
| - name: Install cross-compilation tools | |
| if: matrix.target == 'aarch64-unknown-linux-gnu' | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y gcc-aarch64-linux-gnu | |
| - name: Build release binary | |
| run: cargo build --release --target ${{ matrix.target }} | |
| - name: Strip binary | |
| run: strip target/${{ matrix.target }}/release/${{ matrix.binary_name }} | |
| - name: Create archive | |
| shell: bash | |
| run: | | |
| VERSION=${GITHUB_REF#refs/tags/} | |
| ASSET_NAME="kilar-${VERSION}-${{ matrix.target }}.tar.gz" | |
| tar -czf "${ASSET_NAME}" -C target/${{ matrix.target }}/release ${{ matrix.binary_name }} | |
| echo "ASSET_NAME=${ASSET_NAME}" >> $GITHUB_ENV | |
| - name: Upload Release Asset | |
| uses: softprops/action-gh-release@v1 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| with: | |
| files: ${{ env.ASSET_NAME }} | |
| publish-crates: | |
| name: Publish to crates.io | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - name: Publish to crates.io | |
| run: cargo publish --token ${{ secrets.CRATES_TOKEN }} |