Show HN: Layer – Hide your personal AI files from Git without touching gitignore
TL;DR
'layer' is a Rust CLI that manages .git/info/exclude – the Git feature for local-only ignore rules that most developers overlook.
Key Points
- Problem: Every dev has personal files in the repo (CLAUDE.md, prompt files, scratch notes) that shouldn't be committed but also shouldn't pollute the shared .gitignore.
- Install via Cargo: cargo install git-layer, then layer add CLAUDE.md my-notes/ and layer status.
- The tool writes exclusively to .git/info/exclude – no changes to versioned files, no team conflicts.
Nauti's Take
Small tool, real pain. The proliferation of AI context files in repos is an underestimated team problem – and .
git/info/exclude was always the right answer, just too cumbersome without a wrapper. layer isn't a hype project; it's solid craftwork: minimal scope, clear problem, Rust for reliability.
One caveat: . git/info/exclude doesn't get cloned, so every developer needs the tool locally – that should be more prominent in the docs.
Context
With the rise of AI coding assistants, more and more personal config and prompt files are landing in repos: CLAUDE. md, Cursor rules, custom instructions. These files are developer-specific and don't belong in the shared .
gitignore. layer solves this concrete problem elegantly using a Git mechanism that has existed for years but is rarely used. For teams that rely heavily on AI tools, a workflow utility like this quickly becomes essential.