-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update CI configuration slightly (#366)
* Update CI configuration slightly
- Loading branch information
1 parent
f691b0c
commit 6bd1efc
Showing
10 changed files
with
50 additions
and
125 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,86 +8,43 @@ jobs: | |
name: Rustfmt | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v2 | ||
- name: Install rust | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: stable | ||
components: rustfmt | ||
profile: minimal | ||
override: true | ||
- name: Run rustfmt | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: fmt | ||
args: --all -- --check | ||
- uses: actions/checkout@v3 | ||
- uses: dtolnay/rust-toolchain@stable | ||
- run: cargo fmt --all -- --check | ||
|
||
# Static analyzer. | ||
clippy: | ||
name: Clippy | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v2 | ||
- name: Install rust | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: stable | ||
components: clippy | ||
profile: minimal | ||
override: true | ||
- name: Run clippy | ||
uses: actions-rs/clippy-check@v1 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
args: --all-targets --all-features -- -D warnings | ||
|
||
# Security audit. | ||
audit: | ||
name: Security audit | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions-rs/audit-check@v1 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
- uses: actions/checkout@v3 | ||
- uses: dtolnay/rust-toolchain@stable | ||
- run: cargo clippy --all-targets --all-features -- -D warnings | ||
|
||
# Check links in the documentation. | ||
deadlinks: | ||
name: Deadlinks | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v2 | ||
- name: Install rust | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: stable | ||
profile: minimal | ||
override: true | ||
- name: Install deadlinks | ||
run: cargo install cargo-deadlinks | ||
- name: Cargo doc | ||
run: cargo doc --no-deps -p os_info | ||
- name: Run deadlinks | ||
run: cargo deadlinks --no-build | ||
- uses: actions/checkout@v3 | ||
- uses: dtolnay/rust-toolchain@stable | ||
- run: cargo install cargo-deadlinks | ||
- run: cargo doc --no-deps -p os_info | ||
- run: cargo deadlinks --no-build | ||
|
||
# Check links in markdown files. | ||
mlc: | ||
name: MLC | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v2 | ||
- name: Markup Link Checker (mlc) | ||
uses: becheran/[email protected] | ||
- uses: actions/checkout@v3 | ||
- uses: becheran/[email protected] | ||
|
||
# Spellcheck. | ||
spellcheck: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v3 | ||
- uses: streetsidesoftware/[email protected] | ||
with: | ||
files: "**/*.{rs,md}" | ||
|
@@ -97,10 +54,8 @@ jobs: | |
name: Markdown lints | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v2 | ||
- name: Check md files | ||
uses: nosborn/[email protected] | ||
- uses: actions/checkout@v3 | ||
- uses: nosborn/[email protected] | ||
with: | ||
files: . | ||
|
||
|
@@ -109,7 +64,7 @@ jobs: | |
name: cargo-deny | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v3 | ||
- uses: EmbarkStudios/cargo-deny-action@v1 | ||
|
||
# Tests. | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,30 +6,20 @@ jobs: | |
check: | ||
name: Tarpaulin | ||
runs-on: ubuntu-latest | ||
container: | ||
image: xd009642/tarpaulin:develop-nightly | ||
options: --security-opt seccomp=unconfined | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
uses: actions/checkout@v3 | ||
|
||
- name: Install rust | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: stable | ||
override: true | ||
|
||
- name: Run cargo-tarpaulin | ||
uses: actions-rs/[email protected] | ||
with: | ||
version: latest | ||
args: '-- --test-threads 1' | ||
- name: Generate code coverage | ||
run: | | ||
cargo +nightly tarpaulin --verbose --all-features --workspace --timeout 120 --out xml | ||
- name: Upload to codecov.io | ||
uses: codecov/codecov-action@v1.0.2 | ||
uses: codecov/codecov-action@v4 | ||
with: | ||
token: ${{secrets.CODECOV_TOKEN}} | ||
|
||
- name: Archive code coverage results | ||
uses: actions/upload-artifact@v1 | ||
with: | ||
name: code-coverage-report | ||
path: cobertura.xml | ||
fail_ci_if_error: true |
This file was deleted.
Oops, something went wrong.
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,9 @@ | ||
[workspace] | ||
|
||
members = [ | ||
"os_info", | ||
"cli", | ||
] | ||
|
||
[workspace.dependencies] | ||
log = "0.4" |
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
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
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
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