-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #81 from gendx/workflows
Migrate GitHub actions to dtolnay/rust-toolchain.
- Loading branch information
Showing
5 changed files
with
31 additions
and
61 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 |
---|---|---|
@@ -0,0 +1,15 @@ | ||
on: [push, pull_request] | ||
name: Formatting on stable toolchain | ||
jobs: | ||
format: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: dtolnay/rust-toolchain@stable | ||
with: | ||
components: rustfmt | ||
|
||
- name: Check formatting | ||
run: cargo fmt -- --check | ||
- name: Check formatting on fuzzing | ||
run: cargo fmt --manifest-path fuzz/Cargo.toml -- --check |
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,43 +1,19 @@ | ||
on: [push, pull_request] | ||
name: Lints on stable toolchain | ||
jobs: | ||
lints: | ||
clippy: | ||
runs-on: ubuntu-latest | ||
env: | ||
RUSTFLAGS: "-D warnings" | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions-rs/toolchain@v1 | ||
- uses: dtolnay/rust-toolchain@stable | ||
with: | ||
profile: minimal | ||
toolchain: stable | ||
override: true | ||
components: rustfmt, clippy | ||
|
||
- name: Check formatting | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: fmt | ||
args: -- --check | ||
|
||
- name: Check formatting on fuzzing | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: fmt | ||
args: --manifest-path fuzz/Cargo.toml -- --check | ||
components: clippy | ||
|
||
- name: Check Clippy lints | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: clippy | ||
args: -- -D warnings -W clippy::match-same-arms | ||
|
||
run: cargo clippy -- -W clippy::match-same-arms | ||
- name: Check Clippy lints on tests | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: clippy | ||
args: --tests -- -D warnings -W clippy::match-same-arms | ||
|
||
run: cargo clippy --tests -- -W clippy::match-same-arms | ||
- name: Check Clippy lints on fuzzing | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: clippy | ||
args: --manifest-path fuzz/Cargo.toml -- -D warnings -W clippy::match-same-arms | ||
run: cargo clippy --manifest-path fuzz/Cargo.toml -- -W clippy::match-same-arms |
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