Skip to content

Commit

Permalink
Update rust.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
learturely committed Nov 29, 2024
1 parent e34c21d commit 84d3df6
Showing 1 changed file with 46 additions and 3 deletions.
49 changes: 46 additions & 3 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ name: Rust

on:
push:
branches: [ "main", "newsign" ]
branches: [ "main" ]
pull_request:
branches: [ "main", "newsign" ]
branches: [ "main" ]

env:
CARGO_TERM_COLOR: always
Expand All @@ -39,8 +39,51 @@ jobs:
with:
toolchain: nightly
override: true
components: rustfmt, clippy
components: clippy
- name: Run cargo check
uses: actions-rs/cargo@v1
with:
command: check
- name: Run cargo clippy
uses: actions-rs/cargo@v1
with:
command: clippy
build:
if: true
needs: [ check ]
strategy:
fail-fast: false
matrix:
include:
- { os: ubuntu-latest }
- { os: windows-2022 }
- { os: macos-12 }
name: ${{ format('{0}', matrix.os) }}
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- name: Install libdbus-1-dev
if: ${{ matrix.os == 'ubuntu-latest' }}
run: sudo apt update && sudo apt-get install -yqq libdbus-1-dev
- name: Install latest nightly
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
override: true
- name: Run cargo build
uses: actions-rs/cargo@v1
with:
command: build
args: --release --all-features
- name: Upload artifact
if: ${{ matrix.os != 'windows-2022' }}
uses: actions/upload-artifact@v4
with:
name: '${{ matrix.os }}'
path: '${{ github.workspace }}/target/release/*sign'
- name: Upload artifact (Windows)
if: ${{ matrix.os == 'windows-2022' }}
uses: actions/upload-artifact@v4
with:
name: '${{ matrix.os }}'
path: '${{ github.workspace }}/target/release/*sign.exe'

0 comments on commit 84d3df6

Please sign in to comment.