-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
119 lines (102 loc) · 2.93 KB
/
create-caches.yml
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
name: Create Caches
on:
schedule:
# Run at 0:00 daily. (Basically as early as possible.)
- cron: 0 0 * * *
workflow_dispatch:
# TODO: Remove this. It is for testing purposes only.
pull_request:
# Prevent this workflow from being run more than once at a time.
concurrency:
group: ${{ github.workflow }}
jobs:
build:
name: Build
strategy:
# Don't cancel everything if one configuration happens to fail.
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
toolchain: [stable]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.toolchain }}
- name: Install Linux dependencies
uses: ./.github/actions/install-linux-deps
- name: Build workspace
run: cargo build --workspace
- name: Save cache
uses: ./.github/actions/cache
with:
kind: build
toolchain: ${{ matrix.toolchain }}
action: save
check:
name: Check
strategy:
# Don't cancel everything if one configuration happens to fail.
fail-fast: false
matrix:
include:
- os: ubuntu-latest
toolchain: nightly
target: default
- os: macos-latest
toolchain: nightly
target: default
- os: ubuntu-latest
toolchain: stable
target: wasm
- os: ubuntu-latest
toolchain: nightly
target: wasm-atomics
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.toolchain }}
- name: Install Linux dependencies
uses: ./.github/actions/install-linux-deps
- name: Build workspace
run: cargo check --workspace
- name: Save cache
uses: ./.github/actions/cache
with:
kind: check
toolchain: ${{ matrix.toolchain }}
target: ${{ matrix.target }}
action: save
doc:
name: Doc
strategy:
# Don't cancel everything if one configuration happens to fail.
fail-fast: false
matrix:
os: [ubuntu-latest]
toolchain: [nightly]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.toolchain }}
- name: Install Linux dependencies
uses: ./.github/actions/install-linux-deps
- name: Build workspace
run: cargo doc -p bevy --no-deps
- name: Save cache
uses: ./.github/actions/cache
with:
kind: doc
toolchain: ${{ matrix.toolchain }}
action: save