Action fix #3
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 and Deploy Deb | |
on: | |
push: | |
tags: | |
- "[0-9]+.[0-9]+.[0-9]+" | |
permissions: | |
contents: write | |
jobs: | |
build-and-upload: | |
name: Build Deb and upload | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Get the release version from the tag | |
shell: bash | |
run: echo "VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV | |
- name: Install Rust | |
uses: dtolnay/rust-toolchain@stable | |
- name: Install packages | |
run: sudo apt-get -y install libgtk-3-dev libudev-dev | |
- name: Install cargo-deb | |
uses: actions-rs/cargo@v1 | |
with: | |
command: install | |
args: cargo-deb | |
- name: Build Deb Package | |
uses: actions-rs/cargo@v1 | |
with: | |
command: deb | |
args: --verbose | |
- name: Locate Deb Package | |
shell: bash | |
run: | | |
deb_package=$(ls target/debian/*.deb | head -n 1) | |
echo "ASSET=$deb_package" >> $GITHUB_ENV | |
- name: Upload Deb Package | |
uses: softprops/action-gh-release@v1 | |
with: | |
files: | | |
${{ env.ASSET }} |