-
Notifications
You must be signed in to change notification settings - Fork 106
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
16 changed files
with
407 additions
and
148 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 |
---|---|---|
@@ -1 +1,13 @@ | ||
msrv = "1.64.0" # MSRV | ||
msrv = "1.65.0" # MSRV | ||
warn-on-all-wildcard-imports = true | ||
allow-expect-in-tests = true | ||
allow-unwrap-in-tests = true | ||
allow-dbg-in-tests = true | ||
disallowed-methods = [ | ||
{ path = "std::option::Option::map_or", reason = "prefer `map(..).unwrap_or(..)` for legibility" }, | ||
{ path = "std::option::Option::map_or_else", reason = "prefer `map(..).unwrap_or_else(..)` for legibility" }, | ||
{ path = "std::result::Result::map_or", reason = "prefer `map(..).unwrap_or(..)` for legibility" }, | ||
{ path = "std::result::Result::map_or_else", reason = "prefer `map(..).unwrap_or_else(..)` for legibility" }, | ||
{ path = "std::iter::Iterator::for_each", reason = "prefer `for` for side-effects" }, | ||
{ path = "std::iter::Iterator::try_for_each", reason = "prefer `for` for side-effects" }, | ||
] |
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,26 +1,65 @@ | ||
{ | ||
"schedule": [ | ||
"before 3am on the first day of the month" | ||
schedule: [ | ||
'before 5am on the first day of the month', | ||
], | ||
"semanticCommits": "enabled", | ||
"configMigration": true, | ||
"packageRules": [ | ||
semanticCommits: 'enabled', | ||
configMigration: true, | ||
dependencyDashboard: true, | ||
regexManagers: [ | ||
{ | ||
fileMatch: [ | ||
'^rust-toolchain\\.toml$', | ||
'Cargo.toml$', | ||
'clippy.toml$', | ||
'\\.clippy.toml$', | ||
'^\\.github/workflows/ci.yml$', | ||
'^\\.github/workflows/rust-next.yml$', | ||
], | ||
matchStrings: [ | ||
'MSRV.*?(?<currentValue>\\d+\\.\\d+(\\.\\d+)?)', | ||
'(?<currentValue>\\d+\\.\\d+(\\.\\d+)?).*?MSRV', | ||
], | ||
depNameTemplate: 'rust', | ||
packageNameTemplate: 'rust-lang/rust', | ||
datasourceTemplate: 'github-releases', | ||
}, | ||
], | ||
packageRules: [ | ||
{ | ||
commitMessageTopic: 'MSRV', | ||
matchManagers: [ | ||
'regex', | ||
], | ||
matchPackageNames: [ | ||
'rust', | ||
], | ||
minimumReleaseAge: "126 days", // 3 releases * 6 weeks per release * 7 days per week | ||
internalChecksFilter: "strict", | ||
}, | ||
// Goals: | ||
// - Rollup safe upgrades to reduce CI runner load | ||
// - Have lockfile and manifest in-sync | ||
{ | ||
"matchManagers": ["cargo"], | ||
"matchCurrentVersion": ">=0.1.0", | ||
"matchUpdateTypes": ["patch"], | ||
"automerge": true, | ||
"groupName": "compatible", | ||
matchManagers: [ | ||
'cargo', | ||
], | ||
matchCurrentVersion: '>=0.1.0', | ||
matchUpdateTypes: [ | ||
'patch', | ||
], | ||
automerge: true, | ||
groupName: 'compatible', | ||
}, | ||
{ | ||
"matchManagers": ["cargo"], | ||
"matchCurrentVersion": ">=1.0.0", | ||
"matchUpdateTypes": ["minor"], | ||
"automerge": true, | ||
"groupName": "compatible", | ||
matchManagers: [ | ||
'cargo', | ||
], | ||
matchCurrentVersion: '>=1.0.0', | ||
matchUpdateTypes: [ | ||
'minor', | ||
], | ||
automerge: true, | ||
groupName: 'compatible', | ||
}, | ||
], | ||
} |
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,21 +1,49 @@ | ||
name: Security audit | ||
|
||
permissions: | ||
contents: read | ||
|
||
on: | ||
pull_request: | ||
paths: | ||
- '**/Cargo.toml' | ||
- '**/Cargo.lock' | ||
push: | ||
paths: | ||
- '**/Cargo.toml' | ||
- '**/Cargo.lock' | ||
schedule: | ||
- cron: '3 3 3 * *' | ||
branches: | ||
- master | ||
|
||
env: | ||
RUST_BACKTRACE: 1 | ||
CARGO_TERM_COLOR: always | ||
CLICOLOR: 1 | ||
|
||
jobs: | ||
security_audit: | ||
permissions: | ||
issues: write # to create issues (actions-rs/audit-check) | ||
checks: write # to create check (actions-rs/audit-check) | ||
runs-on: ubuntu-latest | ||
# Prevent sudden announcement of a new advisory from failing ci: | ||
continue-on-error: true | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v3 | ||
- uses: actions-rs/audit-check@v1 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
cargo_deny: | ||
permissions: | ||
issues: write # to create issues (actions-rs/audit-check) | ||
checks: write # to create check (actions-rs/audit-check) | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
checks: | ||
- bans licenses sources | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: EmbarkStudios/cargo-deny-action@v1 | ||
with: | ||
command: check ${{ matrix.checks }} | ||
rust-version: stable |
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
Oops, something went wrong.