-
Notifications
You must be signed in to change notification settings - Fork 48
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 #114 from jonhoo/ci
Move to common CI
- Loading branch information
Showing
18 changed files
with
1,092 additions
and
235 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,21 @@ | ||
# ref: https://docs.codecov.com/docs/codecovyml-reference | ||
coverage: | ||
# Hold ourselves to a high bar | ||
range: 85..100 | ||
round: down | ||
precision: 1 | ||
status: | ||
# ref: https://docs.codecov.com/docs/commit-status | ||
project: | ||
default: | ||
# Avoid false negatives | ||
threshold: 1% | ||
|
||
# Test files aren't important for coverage | ||
ignore: | ||
- "tests" | ||
|
||
# Make comments less noisy | ||
comment: | ||
layout: "files" | ||
require_changes: yes |
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,17 @@ | ||
version: 2 | ||
updates: | ||
- package-ecosystem: github-actions | ||
directory: / | ||
schedule: | ||
interval: daily | ||
- package-ecosystem: cargo | ||
directory: / | ||
schedule: | ||
interval: daily | ||
ignore: | ||
- dependency-name: "*" | ||
# patch and minor updates don't matter for libraries | ||
# remove this ignore rule if your package has binaries | ||
update-types: | ||
- "version-update:semver-patch" | ||
- "version-update:semver-minor" |
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,101 @@ | ||
permissions: | ||
contents: read | ||
on: | ||
push: | ||
branches: [main] | ||
pull_request: | ||
name: check | ||
jobs: | ||
fmt: | ||
runs-on: ubuntu-latest | ||
name: stable / fmt | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
submodules: true | ||
- name: Install stable | ||
uses: dtolnay/rust-toolchain@stable | ||
with: | ||
components: rustfmt | ||
- name: cargo fmt --check | ||
run: cargo fmt --check | ||
clippy: | ||
runs-on: ubuntu-latest | ||
name: ${{ matrix.toolchain }} / clippy | ||
permissions: | ||
contents: read | ||
checks: write | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
toolchain: [stable, beta] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
submodules: true | ||
- name: Install ${{ matrix.toolchain }} | ||
uses: dtolnay/rust-toolchain@master | ||
with: | ||
toolchain: ${{ matrix.toolchain }} | ||
components: clippy | ||
- name: cargo clippy | ||
uses: actions-rs/clippy-check@v1 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
doc: | ||
runs-on: ubuntu-latest | ||
name: nightly / doc | ||
steps: | ||
- uses: actions/checkout@v3 | ||
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 | ||
deny: | ||
runs-on: ubuntu-latest | ||
name: ubuntu / stable / features | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
submodules: true | ||
- name: Install stable | ||
uses: dtolnay/rust-toolchain@stable | ||
- name: cargo install cargo-deny | ||
uses: taiki-e/install-action@cargo-deny | ||
- name: cargo deny | ||
run: cargo deny check | ||
hack: | ||
runs-on: ubuntu-latest | ||
name: ubuntu / stable / features | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
submodules: true | ||
- name: Install stable | ||
uses: dtolnay/rust-toolchain@stable | ||
- name: cargo install cargo-hack | ||
uses: taiki-e/install-action@cargo-hack | ||
- name: cargo hack | ||
run: cargo hack --feature-powerset check --lib --tests | ||
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.56.1] # UnsafeCell::raw_get | ||
name: ubuntu / ${{ matrix.msrv }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
submodules: true | ||
- name: Install ${{ matrix.msrv }} | ||
uses: dtolnay/rust-toolchain@master | ||
with: | ||
toolchain: ${{ matrix.msrv }} | ||
- name: cargo +${{ matrix.msrv }} check | ||
run: cargo 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,24 @@ | ||
permissions: | ||
contents: read | ||
on: | ||
push: | ||
branches: [master] | ||
branches: [main] | ||
pull_request: | ||
name: coverage | ||
jobs: | ||
test: | ||
coverage: | ||
runs-on: ubuntu-latest | ||
container: | ||
image: xd009642/tarpaulin:develop-nightly | ||
options: --security-opt seccomp=unconfined | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v3 | ||
with: | ||
submodules: true | ||
- name: Generate code coverage | ||
run: | | ||
cargo tarpaulin --verbose --all-features --timeout 120 --run-types Doctests --run-types Tests --out Xml | ||
- name: Upload to codecov.io | ||
uses: codecov/codecov-action@v2 | ||
uses: codecov/codecov-action@v3 | ||
with: | ||
fail_ci_if_error: true |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.