Skip to content

Commit de41fd2

Browse files
Merge #440
440: Use GitHub actions for CI r=adamgreig a=therealprof Signed-off-by: Daniel Egger <daniel@eggers-club.de> Co-authored-by: Daniel Egger <daniel@eggers-club.de>
2 parents 3f0e249 + 8771cb8 commit de41fd2

File tree

2 files changed

+76
-0
lines changed

2 files changed

+76
-0
lines changed

.github/workflows/ci.yml

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
on:
2+
push:
3+
branches: [ staging, trying, master ]
4+
pull_request:
5+
6+
name: Continuous integration
7+
8+
jobs:
9+
ci-linux:
10+
runs-on: ubuntu-latest
11+
strategy:
12+
matrix:
13+
# All generated code should be running on stable now
14+
rust: [stable]
15+
16+
# All vendor files we want to test on stable
17+
VENDOR: [rustfmt, Atmel, Freescale, Fujitsu, Holtek, Nordic, Nuvoton, NXP, RISC-V, SiliconLabs, Spansion, STMicro, Toshiba]
18+
19+
# The default target we're compiling on and for
20+
TARGET: [x86_64-unknown-linux-gnu]
21+
22+
# Temporary hack as long as we use the current CI script
23+
TRAVIS_OS_NAME: [linux]
24+
25+
include:
26+
# Test MSRV
27+
- rust: 1.37.0
28+
VENDOR: Nordic
29+
TARGET: x86_64-unknown-linux-gnu
30+
TRAVIS_OS_NAME: linux
31+
32+
# Use nightly for architectures which don't support stable
33+
- rust: nightly
34+
experimental: true
35+
VENDOR: OTHER
36+
TARGET: x86_64-unknown-linux-gnu
37+
TRAVIS_OS_NAME: linux
38+
39+
# OSX
40+
- rust: stable
41+
TARGET: x86_64-apple-darwin
42+
TRAVIS_OS_NAME: osx
43+
44+
# Windows
45+
- rust: stable
46+
TARGET: x86_64-pc-windows-msvc
47+
TRAVIS_OS_NAME: windows
48+
49+
steps:
50+
- uses: actions/checkout@v2
51+
- uses: actions-rs/toolchain@v1
52+
with:
53+
profile: minimal
54+
toolchain: ${{ matrix.rust }}
55+
target: ${{ matrix.TARGET }}
56+
override: true
57+
components: rustfmt
58+
- name: Run CI script for ${{ matrix.VENDOR }} under ${{ matrix.rust }}
59+
run: TARGET=${{ matrix.TARGET }} VENDOR=${{ matrix.VENDOR }} TRAVIS_OS_NAME=${{ matrix.TRAVIS_OS_NAME }} bash ci/script.sh

.github/workflows/clippy.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
on: [push, pull_request]
2+
3+
name: Clippy check
4+
jobs:
5+
clippy_check:
6+
runs-on: ubuntu-latest
7+
steps:
8+
- uses: actions/checkout@v2
9+
- uses: actions-rs/toolchain@v1
10+
with:
11+
profile: minimal
12+
toolchain: stable
13+
override: true
14+
components: clippy
15+
- uses: actions-rs/clippy-check@v1
16+
with:
17+
token: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)