Skip to content

Commit 420d3d7

Browse files
branchseerclaude
andcommitted
chore: add cross-platform clippy recipes to justfile
Add `just lint-linux` and `just lint-windows` for cross-compiling clippy checks via cargo-zigbuild and cargo-xwin, and document them in CLAUDE.md. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 1c7d41e commit 420d3d7

2 files changed

Lines changed: 18 additions & 0 deletions

File tree

CLAUDE.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ just fmt # Format code (cargo fmt, cargo shear, dprint)
1313
just check # Check compilation with all features
1414
just test # Run all tests
1515
just lint # Clippy linting
16+
just lint-linux # Cross-clippy for Linux (requires cargo-zigbuild)
17+
just lint-windows # Cross-clippy for Windows (requires cargo-xwin)
1618
just doc # Documentation generation
1719
```
1820

@@ -88,6 +90,16 @@ Tasks are defined in `vite-task.json`:
8890
- With `-r/--recursive`: runs task across all packages in dependency order
8991
- With `-t/--transitive`: runs task in current package and its dependencies
9092

93+
## Cross-Platform Linting
94+
95+
After major changes (especially to `fspy*` or platform-specific crates), run cross-platform clippy before pushing:
96+
97+
```bash
98+
just lint # native (host platform)
99+
just lint-linux # Linux via cargo-zigbuild
100+
just lint-windows # Windows via cargo-xwin
101+
```
102+
91103
## Code Constraints
92104

93105
These patterns are enforced by `.clippy.toml`:

justfile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,12 @@ test:
4141
lint:
4242
cargo clippy --workspace --all-targets --all-features -- --deny warnings
4343

44+
lint-linux:
45+
cargo-zigbuild clippy --workspace --all-targets --all-features --target x86_64-unknown-linux-gnu -- --deny warnings
46+
47+
lint-windows:
48+
cargo-xwin clippy --workspace --all-targets --all-features --target x86_64-pc-windows-msvc -- --deny warnings
49+
4450
[unix]
4551
doc:
4652
RUSTDOCFLAGS='-D warnings' cargo doc --no-deps --document-private-items

0 commit comments

Comments
 (0)