aboutsummaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorxoviat <[email protected]>2021-03-19 09:09:56 -0500
committerxoviat <[email protected]>2021-03-19 09:09:56 -0500
commitc565deb34a22d3c93fe138bcd9fa5c0244b7bcb1 (patch)
treeeba11c1273f11871a47317902fbb5343f9ee3302 /.github
parent01fd0cd92d93306502dbe9714432cb00264c8e03 (diff)
ci: parallelize and use cache
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/rust.yml89
1 files changed, 86 insertions, 3 deletions
diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml
index 17b8353e3..2ba650ee1 100644
--- a/.github/workflows/rust.yml
+++ b/.github/workflows/rust.yml
@@ -10,17 +10,100 @@ env:
10 CARGO_TERM_COLOR: always 10 CARGO_TERM_COLOR: always
11 11
12jobs: 12jobs:
13 build: 13 ci:
14 runs-on: ubuntu-latest 14 runs-on: ubuntu-latest
15 strategy:
16 matrix:
17 include:
18 - package: embassy
19 target: thumbv7em-none-eabi
20 - package: embassy
21 target: thumbv7em-none-eabi
22 features: log
23 - package: embassy
24 target: thumbv7em-none-eabi
25 features: defmt
26 - package: embassy
27 target: thumbv6m-none-eabi
28 features: defmt
29# - package: embassy-nrf-examples
30# target: thumbv7em-none-eabi
31 - package: embassy-nrf
32 target: thumbv7em-none-eabi
33 features: 52810
34 - package: embassy-nrf
35 target: thumbv7em-none-eabi
36 features: 52832
37 - package: embassy-nrf
38 target: thumbv7em-none-eabi
39 features: 52833
40 - package: embassy-nrf
41 target: thumbv7em-none-eabi
42 features: 52840
43 - package: embassy-nrf
44 target: thumbv7em-none-eabi
45 features: 52840,log
46 - package: embassy-nrf
47 target: thumbv7em-none-eabi
48 features: 52840,defmt
49 - package: embassy-stm32f4-examples
50 target: thumbv7em-none-eabi
51 features: stm32f405
52 - package: embassy-stm32f4
53 target: thumbv7em-none-eabi
54 features: stm32f405
55 - package: embassy-stm32f4
56 target: thumbv7em-none-eabi
57 features: stm32f405,defmt
58 - package: embassy-stm32l0
59 target: thumbv6m-none-eabi
60 features: stm32l0x2
61 - package: embassy-stm32l0
62 target: thumbv6m-none-eabi
63 features: stm32l0x2,defmt
15 64
16 steps: 65 steps:
17 - uses: actions/checkout@v2 66 - uses: actions/checkout@v2
18 - uses: actions-rs/toolchain@v1 67 - uses: actions-rs/toolchain@v1
19 with: 68 with:
20 toolchain: nightly 69 toolchain: nightly
70 target: ${{ matrix.target }}
21 components: rust-src, rustfmt 71 components: rust-src, rustfmt
22 override: true 72 override: true
23 - name: install 73 - name: cache
24 run: rustup target add thumbv7em-none-eabi thumbv6m-none-eabi 74 id: cache-target
75 uses: actions/cache@v2
76 with:
77 path: target
78 key: ${{ runner.os }}-${{ matrix.target }}
79 - uses: actions-rs/cargo@v1
80 with:
81 command: check
82 args: --package ${{ matrix.package }} --features=${{ matrix.features }}
83
84 fmt:
85 runs-on: ubuntu-latest
86 steps:
87 - uses: actions/checkout@v2
88 - uses: actions-rs/toolchain@v1
89 with:
90 toolchain: nightly
91 components: rustfmt
92 override: true
93 - uses: actions-rs/cargo@v1
94 with:
95 command: fmt
96 args: --all -- --check
97
98 nrf_examples:
99 runs-on: ubuntu-latest
100 steps:
101 - uses: actions/checkout@v2
102 - uses: actions-rs/toolchain@v1
103 with:
104 toolchain: nightly
105 components: rust-src, rustfmt
106 target: thumbv7em-none-eabi
107 override: true
25 - name: Build 108 - name: Build
26 run: ./ci.sh 109 run: ./ci.sh