mirror of
https://github.com/pesde-pkg/pesde.git
synced 2024-12-12 11:00:36 +00:00
ci: use rust action
This commit is contained in:
parent
678430f96f
commit
7057211564
2 changed files with 14 additions and 13 deletions
2
.github/workflows/release.yaml
vendored
2
.github/workflows/release.yaml
vendored
|
@ -33,6 +33,7 @@ jobs:
|
|||
name: Build for ${{ matrix.host }}-${{ matrix.arch }}
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: dtolnay/rust-toolchain@stable
|
||||
- name: Set env
|
||||
shell: bash
|
||||
run: |
|
||||
|
@ -80,6 +81,7 @@ jobs:
|
|||
needs: [ build ]
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: dtolnay/rust-toolchain@stable
|
||||
- name: Publish
|
||||
run: cargo publish --token ${{ secrets.CRATES_IO_TOKEN }} --allow-dirty --locked
|
||||
|
||||
|
|
25
.github/workflows/test-and-lint.yaml
vendored
25
.github/workflows/test-and-lint.yaml
vendored
|
@ -11,19 +11,18 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Set up Rust
|
||||
uses: moonrepo/setup-rust@v1
|
||||
- uses: dtolnay/rust-toolchain@stable
|
||||
with:
|
||||
bins: cargo-tarpaulin
|
||||
components: rustfmt, clippy
|
||||
components: clippy, rustfmt
|
||||
|
||||
- name: Install OS dependencies
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install libdbus-1-dev pkg-config
|
||||
|
||||
- name: Run tests
|
||||
run: cargo test --all --all-features
|
||||
# pesde currently does not have any tests. Bring this back when (if) tests are added.
|
||||
# - name: Run tests
|
||||
# run: cargo test --all --all-features
|
||||
|
||||
- name: Check formatting
|
||||
run: cargo fmt --all -- --check
|
||||
|
@ -31,10 +30,10 @@ jobs:
|
|||
- name: Run clippy
|
||||
run: cargo clippy --all --all-targets --all-features -- -D warnings
|
||||
|
||||
- name: Generate coverage report
|
||||
run: cargo tarpaulin --all-features --out xml --exclude-files src/cli/* --exclude-files registry/* --exclude-files src/main.rs --skip-clean
|
||||
|
||||
- name: Upload coverage reports to Codecov
|
||||
uses: codecov/codecov-action@v4.0.1
|
||||
with:
|
||||
token: ${{ secrets.CODECOV_TOKEN }}
|
||||
# - name: Generate coverage report
|
||||
# run: cargo tarpaulin --all-features --out xml --exclude-files src/cli/* --exclude-files registry/* --exclude-files src/main.rs --skip-clean
|
||||
#
|
||||
# - name: Upload coverage reports to Codecov
|
||||
# uses: codecov/codecov-action@v4.0.1
|
||||
# with:
|
||||
# token: ${{ secrets.CODECOV_TOKEN }}
|
Loading…
Reference in a new issue