-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
153 additions
and
23 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# Heavily inspired by the setup of Jon Gjengset | ||
|
||
name: build | ||
|
||
on: | ||
push: | ||
branches: [ "main" ] | ||
pull_request: | ||
|
||
env: | ||
CARGO_TERM_COLOR: always | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
name: ${{ matrix.toolchain }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
toolchain: [stable, beta] | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
- name: Install ${{ matrix.toolchain }} | ||
uses: dtolnay/rust-toolchain@master | ||
with: | ||
toolchain: ${{ matrix.toolchain }} | ||
- name: build | ||
run: cargo build | ||
|
||
msrv: | ||
runs-on: ubuntu-latest | ||
# we use a matrix here just because env can't be used in job names | ||
# https://docs.github.com/en/actions/learn-github-actions/contexts#context-availability | ||
strategy: | ||
matrix: | ||
msrv: ["1.65"] | ||
name: stable / ${{ matrix.msrv }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
- name: Install ${{ matrix.msrv }} | ||
uses: dtolnay/rust-toolchain@master | ||
with: | ||
toolchain: ${{ matrix.msrv }} | ||
- name: cargo +${{ matrix.msrv }} build | ||
run: cargo build |
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,54 @@ | ||
# Heavily inspired by the setup of Jon Gjengset | ||
|
||
name: check | ||
|
||
on: | ||
push: | ||
branches: [ "main" ] | ||
pull_request: | ||
|
||
env: | ||
CARGO_TERM_COLOR: always | ||
|
||
jobs: | ||
fmt: | ||
runs-on: ubuntu-latest | ||
name: stable / fmt | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
- name: Install stable | ||
uses: dtolnay/rust-toolchain@stable | ||
with: | ||
components: rustfmt | ||
- name: cargo fmt | ||
run: cargo fmt --check | ||
|
||
clippy: | ||
runs-on: ubuntu-latest | ||
name: stable / clippy | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
- name: Install stable | ||
uses: dtolnay/rust-toolchain@stable | ||
with: | ||
components: clippy | ||
- name: cargo clippy | ||
run: cargo clippy | ||
|
||
doc: | ||
runs-on: ubuntu-latest | ||
name: nightly / doc | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
- name: Install nightly | ||
uses: dtolnay/rust-toolchain@nightly | ||
- name: cargo doc | ||
run: cargo doc --no-deps --all-features | ||
env: | ||
RUSTDOCFLAGS: --cfg docsrs |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# Heavily inspired by the setup of Jon Gjengset | ||
|
||
name: test | ||
|
||
on: | ||
push: | ||
branches: [ "main" ] | ||
pull_request: | ||
|
||
env: | ||
CARGO_TERM_COLOR: always | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
name: ${{ matrix.toolchain }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
toolchain: [stable, beta] | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
- name: Install ${{ matrix.toolchain }} | ||
uses: dtolnay/rust-toolchain@master | ||
with: | ||
toolchain: ${{ matrix.toolchain }} | ||
- name: test | ||
run: cargo test | ||
|
||
miri: | ||
runs-on: ubuntu-latest | ||
name: nightly / miri | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
- run: | | ||
echo "NIGHTLY=nightly-$(curl -s https://rust-lang.github.io/rustup-components-history/x86_64-unknown-linux-gnu/miri)" >> $GITHUB_ENV | ||
- name: Install ${{ env.NIGHTLY }} | ||
uses: dtolnay/rust-toolchain@master | ||
with: | ||
toolchain: ${{ env.NIGHTLY }} | ||
components: miri | ||
- name: cargo miri test | ||
run: cargo miri test | ||
env: | ||
MIRIFLAGS: "" |
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