dot_claude/skills/git-local-exclude/SKILL.md
Use when keeping files local but out of git history (e.g., ai/, .tasks/, secrets). Use for removing files from git history while retaining them on disk without leaking patterns to .gitignore.
npx skillsauth add nijaru/dotfiles git-local-excludeInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
.git/info/exclude instead of .gitignore for personal or sensitive local files to avoid leaking their existence.ls) before and after any destructive git operations (e.g., filter-repo).git rm --cached) BEFORE applying history-rewriting tools.Immediately add patterns to the local exclude file:
echo "ai/" >> .git/info/exclude
echo ".tasks/" >> .git/info/exclude
Follow this exact sequence to remove from index without deleting from disk:
.git/info/exclude.git rm -r --cached <path>.ls <path>.git commit -m "chore: untrack local context".Use only when data must be purged from all commits:
git filter-repo --path <path> --invert-paths.git remote add origin <url>.git push origin main --force.| File | Committed | Visible | Use Case |
| :--- | :--- | :--- | :--- |
| .gitignore | Yes | Yes | Shared: node_modules/, *.pyc, build artifacts. |
| .git/info/exclude | No | No | Private: ai/, .tasks/, personal notes, secrets. |
| Excuse | Reality |
| :--- | :--- |
| "I'll just use .gitignore for now." | This commits the pattern to history, leaking your private directory structure to the public repo. |
| "The files are already in history, so why bother?" | Untracking prevents future accidental leaks and reduces repo bloat for other contributors. |
| "filter-repo is too dangerous." | Manual untracking (rm --cached) is safe; history rewriting is only for secrets. |
filter-repo removes remotes as a safety measure; re-add with git remote add.ls fails after filter-repo, check .git/filter-repo/commit-map for recovery.ai/ not /ai/).development
Use after completing a bug fix, feature, refactor, or tk task when the first implementation taught enough context to replace it with a simpler, cleaner, or more coherent version before finalizing.
development
Use when writing, migrating, or reviewing Zig code across recent stable versions (0.14-0.16), especially to correct stale syntax or stdlib, build.zig, allocator, formatting, or runtime API knowledge.
documentation
Use when reviewing or revising text (prose, docs, commits) to remove AI patterns and improve voice/clarity.
content-media
Use when fetching X/Twitter post content by URL, or searching for recent X posts.