Skip to content

Commit 43f9e1d

Browse files
authored
docs: discourage rust development on network filesystems (#9)
* docs: require local cargo target on network filesystems * docs: discourage rust development on network filesystems
1 parent b8e9542 commit 43f9e1d

1 file changed

Lines changed: 15 additions & 0 deletions

File tree

ai/common-agent-rules.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,21 @@
2828
- Use `thiserror` for public API error types.
2929
- Use `anyhow` only for internal glue where typed errors are not part of the public contract.
3030

31+
## Build Environment
32+
33+
- Do not treat NFS or other network filesystems as a normal location for Rust
34+
development worktrees. Strongly prefer putting the repository or worktree
35+
itself on local disk.
36+
- If a repository is on NFS or another network filesystem, explicitly warn the
37+
user before running heavy Rust commands. State that compile and link times
38+
can degrade severely and that local-disk worktrees are strongly preferred.
39+
- Continue on NFS only if the user explicitly wants to proceed anyway.
40+
- When proceeding on NFS, place Cargo build artifacts on local disk rather than
41+
inside the repository checkout.
42+
- Prefer a stable repo-specific local target directory such as
43+
`CARGO_TARGET_DIR=/tmp/<repo>-target` for `cargo build`, `cargo test`,
44+
`cargo llvm-cov`, and similar heavy commands.
45+
3146
## File Organization
3247

3348
Keep source files small and focused. Split by behavior or abstraction boundary, not by arbitrary line count.

0 commit comments

Comments
 (0)