add version name to binary #8
Workflow file for this run
This file contains 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: Build linux | |
on: | |
push: | |
tags: | |
- 'v*.*.*' | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
build: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install libelf and gdb | |
run: sudo apt-get install -y libelf-dev libelf1 gdb | |
- name: Create Release | |
id: create_release | |
uses: actions/create-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: ${{ github.ref }} | |
release_name: Release ${{ github.ref }} | |
draft: false | |
prerelease: false | |
- name: Release binary | |
run: | | |
cargo clean | |
cargo build --release | |
tar czf corepipe-linux_x86_64-${{ github.event.release.tag_name }}.tar.gz -C target/release/ corepipe | |
- name: Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
files: | | |
corepipe-linux_x86_64-${{ github.event.release.tag_name }}.tar.gz | |