-
Notifications
You must be signed in to change notification settings - Fork 1
44 lines (38 loc) · 1.11 KB
/
pr.yml
File metadata and controls
44 lines (38 loc) · 1.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
---
name: pr
on:
pull_request:
branches:
- trunk
merge_group:
types: [checks_requested]
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}-${{ github.ref_name == 'trunk' && github.sha || 'any-sha' }}
cancel-in-progress: true
env:
CARGO_REGISTRIES_CRATES_IO_PROTOCOL: sparse
CARGO_NET_RETRY: 10
CARGO_HTTP_TIMEOUT: 60
CARGO_INCREMENTAL: 0
jobs:
check:
name: cargo check
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- uses: actions/checkout@v4
- name: Install Rust
run: |
echo "${CARGO_HOME:-$HOME/.cargo}/bin" >> $GITHUB_PATH
if [ -d $HOME/.cargo ]; then
source $HOME/.cargo/env || true
fi
if ! command -v rustup &> /dev/null ; then
curl --proto '=https' --tlsv1.2 --retry 10 --retry-connrefused -fsSL "https://sh.rustup.rs" | sh -s -- --default-toolchain none -y
source $HOME/.cargo/env || true
fi
rustup toolchain install 1.91
rustup default 1.91
- name: cargo check
run: cargo check --workspace