Skip to content

Commit 924a9df

Browse files
committed
ci: remove windows, add libpcap install
1 parent 249f2be commit 924a9df

File tree

1 file changed

+33
-30
lines changed

1 file changed

+33
-30
lines changed

.github/workflows/rust.yaml

+33-30
Original file line numberDiff line numberDiff line change
@@ -10,40 +10,43 @@ on:
1010

1111
jobs:
1212
build:
13-
1413
runs-on: ubuntu-latest
1514

1615
strategy:
1716
matrix:
1817
rust: [stable, beta, nightly]
19-
os: [ubuntu-latest, windows-latest, macos-latest]
18+
os: [ubuntu-latest, macos-latest]
2019

2120
steps:
22-
- name: Checkout code
23-
uses: actions/checkout@v3
24-
25-
- name: Cache cargo registry
26-
uses: actions/cache@v3
27-
with:
28-
path: |
29-
~/.cargo/registry
30-
~/.cargo/git
31-
key: ${{ runner.os }}-cargo-${{ matrix.rust }}-${{ hashFiles('**/Cargo.lock') }}
32-
restore-keys: |
33-
${{ runner.os }}-cargo-${{ matrix.rust }}-
34-
35-
- name: Set up Rust
36-
uses: actions-rs/toolchain@v1
37-
with:
38-
toolchain: ${{ matrix.rust }}
39-
profile: minimal
40-
override: true
41-
42-
- name: Install dependencies
43-
run: cargo fetch
44-
45-
- name: Build the project
46-
run: cargo build --verbose
47-
48-
- name: Run tests
49-
run: cargo test --verbose
21+
- name: Checkout code
22+
uses: actions/checkout@v3
23+
24+
- name: Install libpcap (Ubuntu)
25+
if: matrix.os == 'ubuntu-latest'
26+
run: sudo apt-get update && sudo apt-get install -y libpcap-dev
27+
28+
- name: Cache cargo registry
29+
uses: actions/cache@v3
30+
with:
31+
path: |
32+
~/.cargo/registry
33+
~/.cargo/git
34+
key: ${{ runner.os }}-cargo-${{ matrix.rust }}-${{ hashFiles('**/Cargo.lock') }}
35+
restore-keys: |
36+
${{ runner.os }}-cargo-${{ matrix.rust }}-
37+
38+
- name: Set up Rust
39+
uses: actions-rs/toolchain@v1
40+
with:
41+
toolchain: ${{ matrix.rust }}
42+
profile: minimal
43+
override: true
44+
45+
- name: Install dependencies
46+
run: cargo fetch
47+
48+
- name: Build the project
49+
run: cargo build --verbose
50+
51+
- name: Run tests
52+
run: cargo test --verbose

0 commit comments

Comments
 (0)