ci: only enable ci cache if not a PR or not a fork (#872)
* ci: only enable ci cache if not a PR or not a fork * add to coverage
This commit is contained in:
parent
2b3c76bf5a
commit
8c3e9669b8
|
@ -12,9 +12,6 @@ jobs:
|
|||
- name: Checkout repository
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Enable Rust cache
|
||||
uses: Swatinem/rust-cache@22c9328bcba27aa81a32b1bef27c7e3c78052531 # 2.0.1
|
||||
|
||||
- name: Set up Rust toolchain
|
||||
uses: dtolnay/rust-toolchain@ba37adf8f94a7d9affce79bd3baff1b9e3189c33 # https://github.com/dtolnay/rust-toolchain/commit/ba37adf8f94a7d9affce79bd3baff1b9e3189c33
|
||||
with:
|
||||
|
|
|
@ -86,6 +86,7 @@ jobs:
|
|||
|
||||
- name: Enable Rust cache
|
||||
uses: Swatinem/rust-cache@22c9328bcba27aa81a32b1bef27c7e3c78052531 # 2.0.1
|
||||
if: ${{ github.event_name != 'pull_request' || ! github.event.pull_request.head.repo.fork }} # If it is a PR, only if not a fork
|
||||
|
||||
- name: Check cargo fmt
|
||||
run: cargo fmt --all -- --check
|
||||
|
@ -226,8 +227,7 @@ jobs:
|
|||
|
||||
- name: Enable Rust cache
|
||||
uses: Swatinem/rust-cache@22c9328bcba27aa81a32b1bef27c7e3c78052531 # 2.0.1
|
||||
with:
|
||||
key: ${{ matrix.info.target }}
|
||||
if: ${{ github.event_name != 'pull_request' || ! github.event.pull_request.head.repo.fork }} # If it is a PR, only if not a fork
|
||||
|
||||
- name: Check
|
||||
uses: ClementTsang/cargo-action@v0.0.3
|
||||
|
|
|
@ -44,6 +44,7 @@ jobs:
|
|||
|
||||
- name: Enable Rust cache
|
||||
uses: Swatinem/rust-cache@22c9328bcba27aa81a32b1bef27c7e3c78052531 # 2.0.1
|
||||
if: ${{ github.event_name != 'pull_request' || ! github.event.pull_request.head.repo.fork }} # If it is a PR, only if not a fork
|
||||
|
||||
- name: Install cargo-llvm-cov
|
||||
run: |
|
||||
|
|
Loading…
Reference in New Issue