Skip to content
This repository was archived by the owner on Apr 14, 2026. It is now read-only.

Commit 24493a8

Browse files
committed
add ci
1 parent 4ce08d3 commit 24493a8

File tree

1 file changed

+48
-0
lines changed

1 file changed

+48
-0
lines changed

.github/workflows/build.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: Build & Release
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*' # Триггер только на теги вида v0.1.0, v1.2.3 и т.д.
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- name: Checkout
14+
uses: actions/checkout@v4
15+
16+
- name: Build in Arch Linux container
17+
run: |
18+
docker run --rm \
19+
-v ${{ github.workspace }}:/project \
20+
-w /project \
21+
archlinux:latest \
22+
bash -c "
23+
pacman -Syu --noconfirm &&
24+
pacman -S --noconfirm cmake clang sfml libpcap curl &&
25+
cmake -B build \
26+
-DCMAKE_BUILD_TYPE=Release \
27+
-DCMAKE_C_COMPILER=clang \
28+
-DCMAKE_CXX_COMPILER=clang++ &&
29+
cmake --build build -j\$(nproc)
30+
"
31+
32+
- name: Create Release
33+
uses: softprops/action-gh-release@v2
34+
with:
35+
files: build/NetPulseMonitor
36+
name: NetPulse Monitor ${{ github.ref_name }}
37+
body: |
38+
## NetPulse Monitor ${{ github.ref_name }}
39+
40+
Built on Arch Linux (latest) with clang.
41+
42+
**Run:**
43+
```bash
44+
chmod +x NetPulseMonitor
45+
xhost +local: && sudo -E ./NetPulseMonitor
46+
```
47+
env:
48+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)