Standard files for new Rust monorepos in the rhi ecosystem.
Copy files to your new repo and replace placeholders:
# Copy all scaffolding files
cp -r scaffolding/. ~/git/new-project/
# Replace placeholders
sed -i 's/PROJECT_NAME/your-project/g' ~/git/new-project/flake.nix
sed -i 's/PROJECT_DESCRIPTION/Your description/g' ~/git/new-project/flake.nix
sed -i 's/PROJECT_NAME/your-project/g' ~/git/new-project/docs/package.json| File | Purpose |
|---|---|
.cargo/config.toml |
Target bloat reduction, mold linker hint |
.envrc |
direnv + nix-direnv integration |
.gitignore |
Standard ignores for Rust + Nix + Node |
.githooks/pre-commit |
fmt → clippy (fast checks first) |
.github/workflows/ci.yml |
CI: fmt, clippy, build, test |
.github/workflows/deploy-docs.yml |
VitePress docs to GitHub Pages |
flake.nix |
Nix dev shell with Rust + mold + bun |
docs/package.json |
VitePress with mermaid plugin |
PROJECT_NAME- lowercase project name (e.g.,interconnect)PROJECT_DESCRIPTION- short description
After copying, you'll also need:
Cargo.toml- workspace manifestcrates/- your crate(s)docs/.vitepress/config.ts- VitePress configdocs/index.md- docs home pageCLAUDE.md- project-specific Claude instructions