-
Notifications
You must be signed in to change notification settings - Fork 94
611 lines (539 loc) · 21.9 KB
/
Copy pathci.yaml
File metadata and controls
611 lines (539 loc) · 21.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
name: CI
on:
push:
branches: [main, 'release/**']
pull_request:
branches: [main, 'release/**']
workflow_dispatch:
inputs:
run_copilot_shell:
description: 'Force run copilot-shell tests (ignore change detection)'
required: false
type: boolean
default: false
run_agent_sec:
description: 'Force run agent-sec-core tests (ignore change detection)'
required: false
type: boolean
default: false
run_agentsight:
description: 'Force run agentsight tests (ignore change detection)'
required: false
type: boolean
default: false
run_tokenless:
description: 'Force run tokenless tests (ignore change detection)'
required: false
type: boolean
default: false
run_ws_ckpt:
description: 'Force run ws-ckpt tests (ignore change detection)'
required: false
type: boolean
default: false
permissions:
contents: read
jobs:
# =========================================================================
# Step 1: Detect which components have changed
# =========================================================================
detect-changes:
name: Detect Changes
runs-on: ubuntu-22.04
outputs:
copilot_shell: ${{ steps.changes.outputs.copilot_shell }}
agent_sec_core: ${{ steps.changes.outputs.agent_sec_core }}
agentsight: ${{ steps.changes.outputs.agentsight }}
tokenless: ${{ steps.changes.outputs.tokenless }}
ws_ckpt: ${{ steps.changes.outputs.ws_ckpt }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 2
- name: Check which components changed
id: changes
run: |
set -e
echo "=== Detect Changes ==="
# Get changed files
if git rev-parse HEAD~1 >/dev/null 2>&1; then
CHANGED=$(git diff --name-only HEAD~1 HEAD || true)
else
CHANGED=$(git diff --name-only --diff-filter=ACMRT HEAD || true)
fi
echo "Changed files:"
echo "$CHANGED"
COPILOT_SHELL=false
AGENT_SEC=false
AGENTSIGHT=false
TOKENLESS=false
WS_CKPT=false
# Path-based detection
if echo "$CHANGED" | grep -q "^src/copilot-shell/"; then
COPILOT_SHELL=true
fi
if echo "$CHANGED" | grep -q "^src/agent-sec-core/"; then
AGENT_SEC=true
fi
if echo "$CHANGED" | grep -q "^src/agentsight/"; then
AGENTSIGHT=true
fi
if echo "$CHANGED" | grep -q "^src/tokenless/"; then
TOKENLESS=true
fi
if echo "$CHANGED" | grep -q "^src/ws-ckpt/"; then
WS_CKPT=true
fi
# Manual override via workflow_dispatch
if [[ "${{ inputs.run_copilot_shell }}" == "true" ]]; then
COPILOT_SHELL=true
fi
if [[ "${{ inputs.run_agent_sec }}" == "true" ]]; then
AGENT_SEC=true
fi
if [[ "${{ inputs.run_agentsight }}" == "true" ]]; then
AGENTSIGHT=true
fi
if [[ "${{ inputs.run_tokenless }}" == "true" ]]; then
TOKENLESS=true
fi
if [[ "${{ inputs.run_ws_ckpt }}" == "true" ]]; then
WS_CKPT=true
fi
echo "copilot_shell=$COPILOT_SHELL" >> $GITHUB_OUTPUT
echo "agent_sec_core=$AGENT_SEC" >> $GITHUB_OUTPUT
echo "agentsight=$AGENTSIGHT" >> $GITHUB_OUTPUT
echo "tokenless=$TOKENLESS" >> $GITHUB_OUTPUT
echo "ws_ckpt=$WS_CKPT" >> $GITHUB_OUTPUT
echo "### Change Detection Results" >> $GITHUB_STEP_SUMMARY
echo "| Component | Changed |" >> $GITHUB_STEP_SUMMARY
echo "|-----------|---------|" >> $GITHUB_STEP_SUMMARY
echo "| copilot-shell | $COPILOT_SHELL |" >> $GITHUB_STEP_SUMMARY
echo "| agent-sec-core | $AGENT_SEC |" >> $GITHUB_STEP_SUMMARY
echo "| agentsight | $AGENTSIGHT |" >> $GITHUB_STEP_SUMMARY
echo "| tokenless | $TOKENLESS |" >> $GITHUB_STEP_SUMMARY
echo "| ws-ckpt | $WS_CKPT |" >> $GITHUB_STEP_SUMMARY
# =========================================================================
# Step 2: Build & Lint copilot-shell
# =========================================================================
build-copilot-shell:
name: Build copilot-shell
needs: detect-changes
if: needs.detect-changes.outputs.copilot_shell == 'true'
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
cache-dependency-path: src/copilot-shell/package-lock.json
- name: Install dependencies
run: cd src/copilot-shell && npm ci
- name: Check formatting
run: |
cd src/copilot-shell
npm run format
git diff --exit-code
- name: Lint
run: cd src/copilot-shell && npm run lint:ci
- name: Build
run: cd src/copilot-shell && npm run build
- name: Type check
run: cd src/copilot-shell && npm run typecheck
- name: Upload build artifacts
uses: actions/upload-artifact@v4
with:
name: build-dist-nodejs20
path: |
src/copilot-shell/packages/*/dist/**/*
src/copilot-shell/package-lock.json
retention-days: 1
# =========================================================================
# Step 3: Test copilot-shell (cli + core in parallel)
# =========================================================================
test-copilot-shell-cli:
name: Test copilot-shell/cli
needs: [detect-changes, build-copilot-shell]
if: needs.detect-changes.outputs.copilot_shell == 'true'
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
cache-dependency-path: src/copilot-shell/package-lock.json
- uses: actions/download-artifact@v4
with:
name: build-dist-nodejs20
path: '.'
- name: Install and build
run: |
cd src/copilot-shell
npm ci
npm run build
- name: Run cli tests
run: |
cd src/copilot-shell
NO_COLOR=true npm run test:ci --workspace=@copilot-shell/cli
test-copilot-shell-core:
name: Test copilot-shell/core
needs: [detect-changes, build-copilot-shell]
if: needs.detect-changes.outputs.copilot_shell == 'true'
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
cache-dependency-path: src/copilot-shell/package-lock.json
- uses: actions/download-artifact@v4
with:
name: build-dist-nodejs20
path: '.'
- name: Install and build
run: |
cd src/copilot-shell
npm ci
npm run build
- name: Run core tests
run: |
cd src/copilot-shell
NO_COLOR=true npm run test:ci --workspace=@copilot-shell/core
# =========================================================================
# Step 4: Test agent-sec-core (Linux only)
# =========================================================================
test-agent-sec-core:
name: Test agent-sec-core
needs: detect-changes
if: needs.detect-changes.outputs.agent_sec_core == 'true'
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: dtolnay/rust-toolchain@stable
with:
toolchain: '1.93.0'
components: llvm-tools-preview
- name: Install cargo-llvm-cov
uses: taiki-e/install-action@cargo-llvm-cov
- name: astral-sh/setup-uv
uses: astral-sh/setup-uv@v8.0.0
with:
python-version: '3.11.6'
- uses: Swatinem/rust-cache@v2
with:
workspaces: src/agent-sec-core/linux-sandbox
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y clang llvm libssl-dev libseccomp-dev bubblewrap
- name: Install diff-cover
run: uv tool install diff-cover
- name: Check formatting
run: |
cd src/agent-sec-core
make python-code-pretty
if ! git diff-index --quiet HEAD --; then
echo "ERROR: Code style check failed. Please run 'make python-code-pretty' locally." >&2
git status --porcelain >&2
exit 1
fi
echo "Code style check passed."
- name: Lint check (incremental)
if: github.event_name == 'pull_request'
run: |
cd src/agent-sec-core
uv run --project agent-sec-cli ruff check --config agent-sec-cli/pyproject.toml --output-format=concise . > ruff_report.txt || true
# Prefix paths to match git-diff repo-root-relative paths
sed -i 's|^\([^: ]*\.py\)|src/agent-sec-core/\1|' ruff_report.txt
cd "$GITHUB_WORKSPACE"
LINT_OUTPUT=$(diff-quality --violations=flake8 --fail-under=100 src/agent-sec-core/ruff_report.txt 2>&1) || true
rm -f src/agent-sec-core/ruff_report.txt
echo "$LINT_OUTPUT"
# Extract violation count from diff-quality output
if echo "$LINT_OUTPUT" | grep -q "Failure"; then
{
echo "### ⚠️ agent-sec-core Lint Warnings (incremental)"
echo ""
echo '以下为 PR 变更行中的 ruff lint 违规(不卡点,仅提示):'
echo ""
echo '```'
echo "$LINT_OUTPUT"
echo '```'
} >> "$GITHUB_STEP_SUMMARY"
echo "::warning::Lint violations found in changed lines. See step summary for details."
else
echo "### ✅ agent-sec-core Lint Check Passed" >> "$GITHUB_STEP_SUMMARY"
fi
- name: Run Python tests with coverage
run: |
cd src/agent-sec-core
make test-python-coverage
- name: Generate coverage summary
if: always()
shell: bash
run: |
cd src/agent-sec-core
if [ -f coverage.xml ]; then
LINE_RATE=$(grep -oP 'line-rate="\K[^"]+' coverage.xml | head -1)
BRANCH_RATE=$(grep -oP 'branch-rate="\K[^"]+' coverage.xml | head -1)
LINES_VALID=$(grep -oP 'lines-valid="\K[^"]+' coverage.xml | head -1)
LINES_COVERED=$(grep -oP 'lines-covered="\K[^"]+' coverage.xml | head -1)
BRANCHES_VALID=$(grep -oP 'branches-valid="\K[^"]+' coverage.xml | head -1)
BRANCHES_COVERED=$(grep -oP 'branches-covered="\K[^"]+' coverage.xml | head -1)
LINE_PCT=$(echo "$LINE_RATE * 100" | bc -l | xargs printf '%.1f')
BRANCH_PCT=$(echo "$BRANCH_RATE * 100" | bc -l | xargs printf '%.1f')
{
echo "### 🧪 agent-sec-core (Python) Test Coverage"
echo ""
echo "| Metric | Coverage | Detail |"
echo "|--------|----------|--------|"
echo "| 🟢 Line Coverage | **${LINE_PCT}%** | ${LINES_COVERED}/${LINES_VALID} lines |"
echo "| 🟢 Branch Coverage | **${BRANCH_PCT}%** | ${BRANCHES_COVERED}/${BRANCHES_VALID} branches |"
} >> "$GITHUB_STEP_SUMMARY"
else
echo "### ⚠️ Coverage report not found" >> "$GITHUB_STEP_SUMMARY"
fi
- name: Check uv.lock in sync with pyproject.toml
run: |
cd src/agent-sec-core/agent-sec-cli
uv lock --check
- name: Check requirements.txt in sync with uv.lock
run: |
cd src/agent-sec-core
make export-requirements
if ! git diff --quiet -- agent-sec-cli/requirements.txt; then
echo "ERROR: agent-sec-cli/requirements.txt is out of sync with uv.lock." >&2
echo "Please run 'make export-requirements' locally and commit the result." >&2
git diff -- agent-sec-cli/requirements.txt >&2
exit 1
fi
echo "requirements.txt is in sync with uv.lock."
- name: Run Rust tests with coverage
run: |
cd src/agent-sec-core
make test-rust-coverage
- name: Generate Rust coverage summary
if: always()
shell: bash
run: |
COV_FILE="src/agent-sec-core/rust-coverage.xml"
if [ -f "$COV_FILE" ]; then
LINE_RATE=$(grep -oP 'line-rate="\K[^"]+' "$COV_FILE" | head -1)
LINES_VALID=$(grep -oP 'lines-valid="\K[^"]+' "$COV_FILE" | head -1)
LINES_COVERED=$(grep -oP 'lines-covered="\K[^"]+' "$COV_FILE" | head -1)
LINE_PCT=$(echo "$LINE_RATE * 100" | bc -l | xargs printf '%.1f')
{
echo "### 🧪 agent-sec-core/linux-sandbox (Rust) Test Coverage"
echo ""
echo "| Metric | Coverage | Detail |"
echo "|--------|----------|--------|"
echo "| 🟢 Line Coverage | **${LINE_PCT}%** | ${LINES_COVERED}/${LINES_VALID} lines |"
echo ""
echo "> ℹ️ cargo-llvm-cov 不支持分支覆盖统计,仅展示行覆盖率。"
} >> "$GITHUB_STEP_SUMMARY"
else
echo "### ⚠️ linux-sandbox Rust coverage report not found" >> "$GITHUB_STEP_SUMMARY"
fi
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
- name: Run openclaw-plugin tests with coverage
run: |
cd src/agent-sec-core
cd openclaw-plugin && npm install
cd ..
make test-openclaw-plugin-coverage
- name: Generate openclaw-plugin coverage summary
if: always()
shell: bash
run: |
COV_FILE="src/agent-sec-core/openclaw-plugin/coverage/cobertura-coverage.xml"
if [ -f "$COV_FILE" ]; then
LINE_RATE=$(grep -oP 'line-rate="\K[^"]+' "$COV_FILE" | head -1)
BRANCH_RATE=$(grep -oP 'branch-rate="\K[^"]+' "$COV_FILE" | head -1)
LINES_VALID=$(grep -oP 'lines-valid="\K[^"]+' "$COV_FILE" | head -1)
LINES_COVERED=$(grep -oP 'lines-covered="\K[^"]+' "$COV_FILE" | head -1)
BRANCHES_VALID=$(grep -oP 'branches-valid="\K[^"]+' "$COV_FILE" | head -1)
BRANCHES_COVERED=$(grep -oP 'branches-covered="\K[^"]+' "$COV_FILE" | head -1)
LINE_PCT=$(echo "$LINE_RATE * 100" | bc -l | xargs printf '%.1f')
BRANCH_PCT=$(echo "$BRANCH_RATE * 100" | bc -l | xargs printf '%.1f')
{
echo "### 🧪 agent-sec-core/openclaw-plugin (TypeScript) Test Coverage"
echo ""
echo "| Metric | Coverage | Detail |"
echo "|--------|----------|--------|"
echo "| 🟢 Line Coverage | **${LINE_PCT}%** | ${LINES_COVERED}/${LINES_VALID} lines |"
echo "| 🟢 Branch Coverage | **${BRANCH_PCT}%** | ${BRANCHES_COVERED}/${BRANCHES_VALID} branches |"
} >> "$GITHUB_STEP_SUMMARY"
else
echo "### ⚠️ openclaw-plugin coverage report not found" >> "$GITHUB_STEP_SUMMARY"
fi
- name: Incremental coverage gate (PR only)
if: github.event_name == 'pull_request'
shell: bash
run: |
cd src/agent-sec-core
COMPARE_BRANCH="origin/${{ github.base_ref }}"
echo "=== Diff-cover: comparing against $COMPARE_BRANCH ==="
DIFF_COV_SUMMARY=""
GATE_FAILED=false
THRESHOLD=80
# Helper: extract coverage stats from diff-cover output
extract_diff_cov_stats() {
local output="$1"
local pct missing total covered
pct=$(echo "$output" | grep -oP 'Coverage:\s*\K[0-9.]+(?=%)' || echo "")
total=$(echo "$output" | grep -oP 'Total:\s+\K[0-9]+' || echo "")
missing=$(echo "$output" | grep -oP 'Missing:\s*\K[0-9]+' || echo "")
if [ -n "$total" ] && [ -n "$missing" ]; then
covered=$((total - missing))
echo "${pct}|${covered}/${total} lines"
elif [ -n "$pct" ]; then
echo "${pct}|-"
else
echo "N/A|-"
fi
}
# --- Python ---
if [ -f coverage.xml ]; then
echo "--- Python incremental coverage ---"
PYTHON_OUTPUT=$(diff-cover coverage.xml --compare-branch="$COMPARE_BRANCH" --fail-under=$THRESHOLD 2>&1) || GATE_FAILED=true
echo "$PYTHON_OUTPUT"
PYTHON_STATS=$(extract_diff_cov_stats "$PYTHON_OUTPUT")
PYTHON_PCT=$(echo "$PYTHON_STATS" | cut -d'|' -f1)
PYTHON_DETAIL=$(echo "$PYTHON_STATS" | cut -d'|' -f2)
DIFF_COV_SUMMARY="${DIFF_COV_SUMMARY}| Python | ${PYTHON_PCT}% | ${PYTHON_DETAIL} | ${THRESHOLD}% |\n"
fi
# --- Rust ---
if [ -f rust-coverage.xml ]; then
echo "--- Rust incremental coverage ---"
RUST_OUTPUT=$(diff-cover rust-coverage.xml --compare-branch="$COMPARE_BRANCH" --fail-under=$THRESHOLD 2>&1) || GATE_FAILED=true
echo "$RUST_OUTPUT"
RUST_STATS=$(extract_diff_cov_stats "$RUST_OUTPUT")
RUST_PCT=$(echo "$RUST_STATS" | cut -d'|' -f1)
RUST_DETAIL=$(echo "$RUST_STATS" | cut -d'|' -f2)
DIFF_COV_SUMMARY="${DIFF_COV_SUMMARY}| Rust | ${RUST_PCT}% | ${RUST_DETAIL} | ${THRESHOLD}% |\n"
fi
# --- TypeScript ---
TS_COV="openclaw-plugin/coverage/cobertura-coverage.xml"
if [ -f "$TS_COV" ]; then
echo "--- TypeScript incremental coverage ---"
TS_OUTPUT=$(diff-cover "$TS_COV" --compare-branch="$COMPARE_BRANCH" --fail-under=$THRESHOLD 2>&1) || GATE_FAILED=true
echo "$TS_OUTPUT"
TS_STATS=$(extract_diff_cov_stats "$TS_OUTPUT")
TS_PCT=$(echo "$TS_STATS" | cut -d'|' -f1)
TS_DETAIL=$(echo "$TS_STATS" | cut -d'|' -f2)
DIFF_COV_SUMMARY="${DIFF_COV_SUMMARY}| TypeScript | ${TS_PCT}% | ${TS_DETAIL} | ${THRESHOLD}% |\n"
fi
# --- Summary ---
{
echo "### 🚦 Incremental Coverage Gate (new/changed code)"
echo ""
echo "| Language | New Code Coverage | Detail | Threshold |"
echo "|----------|-------------------|--------|-----------|"
echo -e "$DIFF_COV_SUMMARY"
if [ "$GATE_FAILED" = true ]; then
echo ""
echo "> ❌ **Gate FAILED**: New code coverage is below ${THRESHOLD}%. Please add tests for uncovered changes."
else
echo ""
echo "> ✅ **Gate PASSED**: All new code meets the ${THRESHOLD}% coverage threshold."
fi
} >> "$GITHUB_STEP_SUMMARY"
if [ "$GATE_FAILED" = true ]; then
echo "::error::Incremental coverage gate failed: new code coverage < ${THRESHOLD}%"
exit 1
fi
# =========================================================================
# Step 5: Test agentsight (Linux only)
# =========================================================================
test-agentsight:
name: Test agentsight
needs: detect-changes
if: needs.detect-changes.outputs.agentsight == 'true'
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
toolchain: '1.89.0'
- uses: Swatinem/rust-cache@v2
with:
workspaces: src/agentsight
- name: Install eBPF build dependencies
run: |
sudo apt-get update
sudo apt-get install -y clang llvm libbpf-dev libelf-dev elfutils libssl-dev zlib1g-dev pkg-config
sudo apt-get install -y perl
- name: Run tests
run: |
rustup component add rustfmt
cd src/agentsight
cargo test
# =========================================================================
# Step 6: Test tokenless
# =========================================================================
test-tokenless:
name: Test tokenless
needs: detect-changes
if: needs.detect-changes.outputs.tokenless == 'true'
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
toolchain: '1.89.0'
components: 'rustfmt, clippy'
- uses: Swatinem/rust-cache@v2
with:
workspaces: src/tokenless
- name: Check formatting
run: |
cd src/tokenless
cargo fmt -p tokenless-cli -p tokenless-schema -p tokenless-stats -- --check
- name: Lint
run: |
cd src/tokenless
cargo clippy -p tokenless-cli -p tokenless-schema -p tokenless-stats -- -D warnings
- name: Run tests
run: |
cd src/tokenless
cargo test -p tokenless-cli -p tokenless-schema -p tokenless-stats
# =========================================================================
# Step 7: Test ws-ckpt
# =========================================================================
test-ws-ckpt:
name: Test ws-ckpt
needs: detect-changes
if: needs.detect-changes.outputs.ws_ckpt == 'true'
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: 'rustfmt, clippy'
- uses: Swatinem/rust-cache@v2
with:
workspaces: src/ws-ckpt/src
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y btrfs-progs rsync
- name: Check formatting
run: |
cd src/ws-ckpt/src
cargo fmt --all --check
- name: Lint
run: |
cd src/ws-ckpt/src
cargo clippy --workspace -- -D warnings
- name: Run tests
run: |
cd src/ws-ckpt/src
cargo test --workspace