Skip to content

Commit 680e29c

Browse files
committed
Add FreeBSD CI job, update to 1.87 (FreeBSD 14.3) and fix clippy lints
1 parent e55afdc commit 680e29c

File tree

12 files changed

+109
-115
lines changed

12 files changed

+109
-115
lines changed

.github/workflows/ci.yml

Lines changed: 46 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
name: Compile Check
1313
runs-on: ubuntu-latest
1414
steps:
15-
- uses: actions/checkout@v3
15+
- uses: actions/checkout@v4
1616
- name: Setup Rust
1717
uses: './.github/actions/ci-rust-setup'
1818
with:
@@ -23,7 +23,7 @@ jobs:
2323
name: Formatter
2424
runs-on: ubuntu-latest
2525
steps:
26-
- uses: actions/checkout@v3
26+
- uses: actions/checkout@v4
2727
- name: Setup Rust
2828
uses: './.github/actions/ci-rust-setup'
2929
with:
@@ -34,13 +34,55 @@ jobs:
3434
name: Run Tests
3535
runs-on: ubuntu-latest
3636
steps:
37-
- uses: actions/checkout@v3
37+
- uses: actions/checkout@v4
3838
- name: Setup Rust
3939
uses: './.github/actions/ci-rust-setup'
4040
with:
4141
cache-name: test
4242
- run: cargo test --lib --all-features
4343

44+
test-freebsd:
45+
runs-on: ubuntu-latest
46+
name: Run Tests in FreeBSD
47+
env:
48+
FREEBSD_VER: "14.3"
49+
steps:
50+
- uses: actions/checkout@v4
51+
- name: Cache dependencies for FreeBSD
52+
uses: actions/cache@v3
53+
with:
54+
path: |
55+
.cargohome/registry
56+
.cargohome/git
57+
target
58+
key: freebsd-${{ env.FREEBSD_VER }}-cargo-test-${{ hashFiles('**/Cargo.lock') }}
59+
- name: Test in FreeBSD
60+
uses: vmactions/freebsd-vm@v1
61+
with:
62+
usesh: true
63+
release: "${{ env.FREEBSD_VER }}"
64+
arch: amd64
65+
prepare: |
66+
mkdir -p ~/.cargo/
67+
mkdir -p ./.cargohome/registry/
68+
mkdir -p ./.cargohome/git/
69+
mv ./.cargohome/registry ~/.cargo/
70+
mv ./.cargohome/git ~/.cargo/
71+
rm -rf ./.cargohome
72+
pkg install -y git rsync gmake llvm rust
73+
74+
run: |
75+
cargo check --no-default-features
76+
cargo check -F liquid
77+
cargo check -F electrum-discovery
78+
cargo check -F electrum-discovery,liquid
79+
rm -rf ./.cargohome
80+
mkdir -p ~/.cargo/registry/
81+
mkdir -p ~/.cargo/git/
82+
mkdir -p ./.cargohome/
83+
mv ~/.cargo/registry ./.cargohome/
84+
mv ~/.cargo/git ./.cargohome/
85+
4486
clippy:
4587
name: Linter
4688
runs-on: ubuntu-latest
@@ -54,7 +96,7 @@ jobs:
5496
'-F electrum-discovery,liquid',
5597
]
5698
steps:
57-
- uses: actions/checkout@v3
99+
- uses: actions/checkout@v4
58100
- name: Setup Rust
59101
uses: './.github/actions/ci-rust-setup'
60102
with:

0 commit comments

Comments
 (0)