Merge pull request #328 from michaelb/dev #62
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*" | |
| workflow_dispatch: | |
| env: | |
| CARGO_TERM_COLOR: always | |
| RUSTFLAGS: -C target-feature=+crt-static | |
| permissions: | |
| contents: write | |
| jobs: | |
| release: | |
| name: Publish release | |
| runs-on: ubuntu-22.04 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| persist-credentials: false | |
| # pinned rust toolchain to 1.88; since using a non-pinned action | |
| # in a wrokflow that produce distributed executables is something | |
| # of a security risk | |
| - uses: dtolnay/rust-toolchain@e2d9ac80ead8661a2e202b02724382f7a4eb1e1d | |
| - name: build | |
| run: cargo build --target x86_64-unknown-linux-gnu --locked --release --verbose && mv ./target/x86_64-unknown-linux-gnu/release/sniprun . | |
| - name: upload to releases | |
| uses: svenstaro/upload-release-action@04733e069f2d7f7f0b4aebc4fbdbce8613b03ccd | |
| with: | |
| repo_token: ${{ secrets.GITHUB_TOKEN }} | |
| file: sniprun | |
| tag: ${{github.ref}} | |
| overwrite: false | |
| body: "This release and associated artifacts were created by Github Action. See the changelog [here](https://github.com/michaelb/sniprun/blob/master/CHANGELOG.md)." |