mirror of
https://github.com/crate-ci/typos.git
synced 2024-11-22 09:01:04 -05:00
chore(ci): Lower server load on PR
This commit is contained in:
parent
a92ae9b6f9
commit
18626e5d2d
2 changed files with 79 additions and 26 deletions
27
.github/workflows/ci.yml
vendored
27
.github/workflows/ci.yml
vendored
|
@ -14,8 +14,6 @@ on:
|
||||||
- '!/*.md'
|
- '!/*.md'
|
||||||
- '!/docs/**'
|
- '!/docs/**'
|
||||||
- "!/LICENSE-*"
|
- "!/LICENSE-*"
|
||||||
schedule:
|
|
||||||
- cron: '3 3 3 * *'
|
|
||||||
jobs:
|
jobs:
|
||||||
smoke:
|
smoke:
|
||||||
name: Quick Check
|
name: Quick Check
|
||||||
|
@ -42,10 +40,7 @@ jobs:
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
os: ["ubuntu-latest", "windows-latest", "macos-latest"]
|
os: ["ubuntu-latest", "windows-latest", "macos-latest"]
|
||||||
rust: ["stable", "beta"]
|
rust: ["stable"]
|
||||||
include:
|
|
||||||
- os: ubuntu-latest
|
|
||||||
rust: "nightly"
|
|
||||||
continue-on-error: ${{ matrix.rust != 'stable' }}
|
continue-on-error: ${{ matrix.rust != 'stable' }}
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
steps:
|
steps:
|
||||||
|
@ -136,23 +131,3 @@ jobs:
|
||||||
with:
|
with:
|
||||||
token: ${{ secrets.GITHUB_TOKEN }}
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
args: --workspace --all-features --all-targets -- -D warnings
|
args: --workspace --all-features --all-targets -- -D warnings
|
||||||
clippy-next:
|
|
||||||
name: clippy (next)
|
|
||||||
needs: clippy
|
|
||||||
continue-on-error: true
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout repository
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
- name: Install Rust
|
|
||||||
uses: actions-rs/toolchain@v1
|
|
||||||
with:
|
|
||||||
toolchain: stable
|
|
||||||
profile: minimal
|
|
||||||
override: true
|
|
||||||
components: clippy
|
|
||||||
- uses: Swatinem/rust-cache@v1
|
|
||||||
- uses: actions-rs/clippy-check@v1
|
|
||||||
with:
|
|
||||||
token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
args: --workspace --all-features --all-targets -- -D warnings
|
|
||||||
|
|
78
.github/workflows/rust-next.yml
vendored
Normal file
78
.github/workflows/rust-next.yml
vendored
Normal file
|
@ -0,0 +1,78 @@
|
||||||
|
name: rust-next
|
||||||
|
on:
|
||||||
|
schedule:
|
||||||
|
- cron: '3 3 3 * *'
|
||||||
|
jobs:
|
||||||
|
test:
|
||||||
|
name: Test
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
os: ["ubuntu-latest", "windows-latest", "macos-latest"]
|
||||||
|
rust: ["stable", "beta"]
|
||||||
|
include:
|
||||||
|
- os: ubuntu-latest
|
||||||
|
rust: "nightly"
|
||||||
|
continue-on-error: ${{ matrix.rust != 'stable' }}
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
|
steps:
|
||||||
|
- name: Checkout repository
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
- name: Install Rust
|
||||||
|
uses: actions-rs/toolchain@v1
|
||||||
|
with:
|
||||||
|
toolchain: ${{ matrix.rust }}
|
||||||
|
profile: minimal
|
||||||
|
override: true
|
||||||
|
- uses: Swatinem/rust-cache@v1
|
||||||
|
- name: Default features
|
||||||
|
run: cargo test --workspace
|
||||||
|
- name: All features
|
||||||
|
run: cargo test --workspace --all-features
|
||||||
|
- name: No-default features
|
||||||
|
run: cargo test --workspace --no-default-features
|
||||||
|
rustfmt:
|
||||||
|
name: rustfmt
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
rust:
|
||||||
|
- stable
|
||||||
|
- beta
|
||||||
|
continue-on-error: ${{ matrix.rust != 'stable' }}
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout repository
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
- name: Install Rust
|
||||||
|
uses: actions-rs/toolchain@v1
|
||||||
|
with:
|
||||||
|
toolchain: ${{ matrix.rust }}
|
||||||
|
profile: minimal
|
||||||
|
override: true
|
||||||
|
components: rustfmt
|
||||||
|
- uses: Swatinem/rust-cache@v1
|
||||||
|
- name: Check formatting
|
||||||
|
run: cargo fmt --all -- --check
|
||||||
|
clippy:
|
||||||
|
name: clippy
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
rust:
|
||||||
|
- 1.53.0 # MSRV
|
||||||
|
- stable
|
||||||
|
continue-on-error: ${{ matrix.rust != '1.53.0' }} # MSRV
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout repository
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
- name: Install Rust
|
||||||
|
uses: actions-rs/toolchain@v1
|
||||||
|
with:
|
||||||
|
toolchain: ${{ matrix.rust }}
|
||||||
|
profile: minimal
|
||||||
|
override: true
|
||||||
|
components: clippy
|
||||||
|
- uses: Swatinem/rust-cache@v1
|
||||||
|
- uses: actions-rs/clippy-check@v1
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
args: --workspace --all-features --all-targets -- -D warnings
|
Loading…
Reference in a new issue