mirror of
https://github.com/ratatui-org/ratatui
synced 2024-11-10 07:04:17 +00:00
chore: cache dependencies in the CI workflow to speed up builds (#883)
This commit is contained in:
parent
bbcfa55a88
commit
984afd580b
1 changed files with 18 additions and 6 deletions
24
.github/workflows/ci.yml
vendored
24
.github/workflows/ci.yml
vendored
|
@ -42,6 +42,8 @@ jobs:
|
||||||
components: rustfmt
|
components: rustfmt
|
||||||
- name: Install cargo-make
|
- name: Install cargo-make
|
||||||
uses: taiki-e/install-action@cargo-make
|
uses: taiki-e/install-action@cargo-make
|
||||||
|
- name: Cache Cargo dependencies
|
||||||
|
uses: Swatinem/rust-cache@v2
|
||||||
- name: Check formatting
|
- name: Check formatting
|
||||||
run: cargo make lint-format
|
run: cargo make lint-format
|
||||||
- name: Check documentation
|
- name: Check documentation
|
||||||
|
@ -67,6 +69,8 @@ jobs:
|
||||||
components: clippy
|
components: clippy
|
||||||
- name: Install cargo-make
|
- name: Install cargo-make
|
||||||
uses: taiki-e/install-action@cargo-make
|
uses: taiki-e/install-action@cargo-make
|
||||||
|
- name: Cache Cargo dependencies
|
||||||
|
uses: Swatinem/rust-cache@v2
|
||||||
- name: Run cargo make clippy-all
|
- name: Run cargo make clippy-all
|
||||||
run: cargo make clippy
|
run: cargo make clippy
|
||||||
|
|
||||||
|
@ -83,6 +87,8 @@ jobs:
|
||||||
uses: taiki-e/install-action@v2
|
uses: taiki-e/install-action@v2
|
||||||
with:
|
with:
|
||||||
tool: cargo-llvm-cov,cargo-make
|
tool: cargo-llvm-cov,cargo-make
|
||||||
|
- name: Cache Cargo dependencies
|
||||||
|
uses: Swatinem/rust-cache@v2
|
||||||
- name: Generate coverage
|
- name: Generate coverage
|
||||||
run: cargo make coverage
|
run: cargo make coverage
|
||||||
- name: Upload to codecov.io
|
- name: Upload to codecov.io
|
||||||
|
@ -95,8 +101,8 @@ jobs:
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
os: [ ubuntu-latest, windows-latest, macos-latest ]
|
os: [ubuntu-latest, windows-latest, macos-latest]
|
||||||
toolchain: [ "1.70.0", "stable" ]
|
toolchain: ["1.70.0", "stable"]
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
|
@ -107,6 +113,8 @@ jobs:
|
||||||
toolchain: ${{ matrix.toolchain }}
|
toolchain: ${{ matrix.toolchain }}
|
||||||
- name: Install cargo-make
|
- name: Install cargo-make
|
||||||
uses: taiki-e/install-action@cargo-make
|
uses: taiki-e/install-action@cargo-make
|
||||||
|
- name: Cache Cargo dependencies
|
||||||
|
uses: Swatinem/rust-cache@v2
|
||||||
- name: Run cargo make check
|
- name: Run cargo make check
|
||||||
run: cargo make check
|
run: cargo make check
|
||||||
env:
|
env:
|
||||||
|
@ -116,7 +124,7 @@ jobs:
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
os: [ ubuntu-latest, windows-latest, macos-latest ]
|
os: [ubuntu-latest, windows-latest, macos-latest]
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
|
@ -125,6 +133,8 @@ jobs:
|
||||||
uses: dtolnay/rust-toolchain@stable
|
uses: dtolnay/rust-toolchain@stable
|
||||||
- name: Install cargo-make
|
- name: Install cargo-make
|
||||||
uses: taiki-e/install-action@cargo-make
|
uses: taiki-e/install-action@cargo-make
|
||||||
|
- name: Cache Cargo dependencies
|
||||||
|
uses: Swatinem/rust-cache@v2
|
||||||
- name: Test docs
|
- name: Test docs
|
||||||
run: cargo make test-doc
|
run: cargo make test-doc
|
||||||
env:
|
env:
|
||||||
|
@ -134,9 +144,9 @@ jobs:
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
os: [ ubuntu-latest, windows-latest, macos-latest ]
|
os: [ubuntu-latest, windows-latest, macos-latest]
|
||||||
toolchain: [ "1.70.0", "stable" ]
|
toolchain: ["1.70.0", "stable"]
|
||||||
backend: [ crossterm, termion, termwiz ]
|
backend: [crossterm, termion, termwiz]
|
||||||
exclude:
|
exclude:
|
||||||
# termion is not supported on windows
|
# termion is not supported on windows
|
||||||
- os: windows-latest
|
- os: windows-latest
|
||||||
|
@ -153,6 +163,8 @@ jobs:
|
||||||
uses: taiki-e/install-action@cargo-make
|
uses: taiki-e/install-action@cargo-make
|
||||||
- name: Install cargo-nextest
|
- name: Install cargo-nextest
|
||||||
uses: taiki-e/install-action@nextest
|
uses: taiki-e/install-action@nextest
|
||||||
|
- name: Cache Cargo dependencies
|
||||||
|
uses: Swatinem/rust-cache@v2
|
||||||
- name: Test ${{ matrix.backend }}
|
- name: Test ${{ matrix.backend }}
|
||||||
run: cargo make test-backend ${{ matrix.backend }}
|
run: cargo make test-backend ${{ matrix.backend }}
|
||||||
env:
|
env:
|
||||||
|
|
Loading…
Reference in a new issue