Skip to content

Commit ca4027a

Browse files
committed
GHA workflows: use matrix to handle community/enterprise
1 parent c2d7d1c commit ca4027a

File tree

4 files changed

+53
-42
lines changed

4 files changed

+53
-42
lines changed

.github/workflows/build.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: Build
2+
3+
on:
4+
push
5+
6+
env:
7+
CARGO_TERM_COLOR: always
8+
LIBCLANG_PATH: /usr/lib/llvm-14/lib/
9+
10+
jobs:
11+
build:
12+
runs-on: ubuntu-22.04
13+
strategy:
14+
matrix:
15+
version: [community, enterprise]
16+
steps:
17+
- name: Install apt-get
18+
run: sudo apt-get install -y clang llvm
19+
- uses: actions/checkout@v3
20+
- name: Build
21+
run: cargo build --features=${{ matrix.version }} --verbose

.github/workflows/clippy.yml

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,14 @@ env:
99
jobs:
1010
clippy_check:
1111
runs-on: ubuntu-latest
12+
strategy:
13+
matrix:
14+
version: [community, enterprise]
1215
steps:
1316
- uses: actions/checkout@v1
1417
- run: rustup component add clippy
1518
- uses: actions-rs/clippy-check@v1
1619
with:
1720
token: ${{ secrets.GITHUB_TOKEN }}
18-
name: Clippy - community
19-
args: --features=community
20-
- uses: actions-rs/clippy-check@v1
21-
with:
22-
token: ${{ secrets.GITHUB_TOKEN }}
23-
name: Clippy - enterprise
24-
args: --features=enterprise
21+
name: Clippy
22+
args: --features=${{ matrix.version }}

.github/workflows/rust.yml

Lines changed: 0 additions & 35 deletions
This file was deleted.

.github/workflows/test.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Test
2+
3+
on:
4+
push
5+
6+
env:
7+
CARGO_TERM_COLOR: always
8+
LIBCLANG_PATH: /usr/lib/llvm-14/lib/
9+
10+
jobs:
11+
build:
12+
runs-on: ubuntu-22.04
13+
strategy:
14+
matrix:
15+
version: [community, enterprise]
16+
steps:
17+
- name: Install apt-get
18+
run: sudo apt-get install -y clang llvm
19+
- name: Install latest nightly
20+
uses: dtolnay/rust-toolchain@v1
21+
with:
22+
toolchain: nightly
23+
components: rustfmt, clippy
24+
- name: Run tests
25+
run: cargo test --features=${{ matrix.version }} --verbose
26+
- name: Run tests (with address sanitizer)
27+
run: LSAN_OPTIONS=suppressions=san.supp RUSTFLAGS="-Zsanitizer=address" cargo +nightly test --features=--features=${{ matrix.version }} --verbose

0 commit comments

Comments
 (0)