-
Notifications
You must be signed in to change notification settings - Fork 1
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
1 parent
54b7ce5
commit dfc282a
Showing
7 changed files
with
186 additions
and
2 deletions.
There are no files selected for viewing
Validating CODEOWNERS rules …
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 @@ | ||
* @mobilecoinfoundation/coredev |
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,9 +1,21 @@ | ||
version: 2 | ||
updates: | ||
- package-ecosystem: cargo | ||
directory: "/" | ||
schedule: | ||
interval: daily | ||
open-pull-requests-limit: 25 | ||
commit-message: | ||
prefix: "chore(deps)" | ||
reviewers: | ||
- "mobilecoinfoundation/coredev" | ||
|
||
- package-ecosystem: github-actions | ||
directory: "/" | ||
schedule: | ||
interval: daily | ||
open-pull-requests-limit: 10 | ||
commit-message: | ||
prefix: "chore(deps)" | ||
reviewers: | ||
- "mobilecoinfoundation/coredev" |
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 |
---|---|---|
|
@@ -6,14 +6,31 @@ on: | |
- 'main' | ||
pull_request: | ||
|
||
env: | ||
CARGO_INCREMENTAL: 0 | ||
RUSTFLAGS: "-Dwarnings" | ||
CARGO_UNSTABLE_SPARSE_REGISTRY: true | ||
|
||
jobs: | ||
buf-lint: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: bufbuild/[email protected] | ||
with: | ||
github_token: ${{ github.token }} | ||
- uses: bufbuild/buf-lint-action@v1 | ||
|
||
rustfmt: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: dtolnay/rust-toolchain@stable | ||
with: | ||
components: rustfmt | ||
- uses: r7kamura/rust-problem-matchers@v1 | ||
- run: cargo fmt --all -- --check | ||
|
||
markdown-lint: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
|
@@ -23,12 +40,144 @@ jobs: | |
with: | ||
globs: "**/*.md" | ||
|
||
deny: | ||
runs-on: ubuntu-22.04 | ||
needs: | ||
- "rustfmt" | ||
- "markdown-lint" | ||
strategy: | ||
matrix: | ||
checks: | ||
- advisories | ||
- bans licenses sources | ||
# Prevent sudden announcement of a new advisory from failing ci: | ||
continue-on-error: ${{ matrix.checks == 'advisories' }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: EmbarkStudios/cargo-deny-action@v1 | ||
with: | ||
command: check ${{ matrix.checks }} | ||
|
||
sort: | ||
runs-on: ubuntu-22.04 | ||
needs: | ||
- "rustfmt" | ||
- "markdown-lint" | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: dtolnay/rust-toolchain@stable | ||
- run: cargo install cargo-sort | ||
- run: cargo sort --workspace --check >/dev/null | ||
|
||
clippy: | ||
runs-on: ubuntu-22.04 | ||
needs: | ||
- "rustfmt" | ||
- "markdown-lint" | ||
strategy: | ||
matrix: | ||
rust: | ||
- stable | ||
- beta | ||
# Prevent beta warnings from causing CI failure | ||
continue-on-error: ${{ matrix.rust == 'beta' }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: dtolnay/rust-toolchain@master | ||
with: | ||
toolchain: ${{ matrix.rust }} | ||
components: clippy | ||
- uses: r7kamura/rust-problem-matchers@v1 | ||
- run: cargo +${{ matrix.rust }} clippy --all --all-features -- -D warnings | ||
|
||
build: | ||
runs-on: ubuntu-22.04 | ||
needs: | ||
- "rustfmt" | ||
- "markdown-lint" | ||
strategy: | ||
matrix: | ||
rust: | ||
- stable | ||
- beta | ||
- nightly-2023-01-04 | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: dtolnay/rust-toolchain@master | ||
with: | ||
toolchain: ${{ matrix.rust }} | ||
- uses: r7kamura/rust-problem-matchers@v1 | ||
- run: cargo +${{ matrix.rust }} build --release | ||
|
||
test: | ||
runs-on: ubuntu-22.04 | ||
needs: | ||
- "rustfmt" | ||
- "markdown-lint" | ||
strategy: | ||
matrix: | ||
rust: | ||
- stable | ||
- beta | ||
- nightly-2023-01-04 | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: dtolnay/rust-toolchain@master | ||
with: | ||
toolchain: ${{ matrix.rust }} | ||
- uses: r7kamura/rust-problem-matchers@v1 | ||
- run: cargo +${{ matrix.rust }} test --release | ||
|
||
doc: | ||
runs-on: ubuntu-22.04 | ||
needs: | ||
- "rustfmt" | ||
- "markdown-lint" | ||
strategy: | ||
matrix: | ||
rust: | ||
- stable | ||
- beta | ||
# Prevent beta warnings from causing CI failure | ||
continue-on-error: ${{ matrix.rust == 'beta' }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: dtolnay/rust-toolchain@master | ||
with: | ||
toolchain: ${{ matrix.rust }} | ||
- uses: r7kamura/rust-problem-matchers@v1 | ||
- run: cargo +${{ matrix.rust }} doc --release --no-deps | ||
|
||
coverage: | ||
runs-on: ubuntu-22.04 | ||
needs: | ||
- "rustfmt" | ||
- "markdown-lint" | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: dtolnay/rust-toolchain@stable | ||
with: | ||
components: llvm-tools-preview | ||
- uses: taiki-e/install-action@cargo-llvm-cov | ||
- run: cargo llvm-cov --workspace --lcov --output-path lcov.info | ||
- uses: codecov/codecov-action@v3 | ||
with: | ||
files: lcov.info | ||
|
||
notify: | ||
runs-on: ubuntu-latest | ||
if: ${{always()}} && ${{failure()}} && ${{ github.event_name }} == 'push' | ||
if: failure() && ${{ github.event_name }} == 'push' | ||
needs: | ||
- buf-lint | ||
- rustfmt | ||
- markdown-lint | ||
- deny | ||
- sort | ||
- clippy | ||
- build | ||
- test | ||
- doc | ||
- coverage | ||
steps: | ||
- name: Notify Discord on failure | ||
uses: sarisia/actions-status-discord@v1 | ||
|
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 |
---|---|---|
|
@@ -15,3 +15,11 @@ jobs: | |
repo-token: "${{ secrets.GITHUB_TOKEN }}" | ||
configuration-path: .github/triage-labeler.yaml | ||
enable-versioned-regex: 0 | ||
|
||
add-to-project: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/[email protected] | ||
with: | ||
github-token: "${{ secrets.ADD_TO_PROJECT_PAT }}" | ||
project-url: https://github.com/orgs/mobilecoinfoundation/projects/5 |
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 |
---|---|---|
|
@@ -4,6 +4,14 @@ on: | |
pull_request: | ||
|
||
jobs: | ||
add-to-project: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/[email protected] | ||
with: | ||
github-token: "${{ secrets.ADD_TO_PROJECT_PAT }}" | ||
project-url: https://github.com/orgs/mobilecoinfoundation/projects/5 | ||
|
||
size-label: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
|
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