Problem
When working on a project, developers often create local-only files that should never be committed: personal scripts, IDE/editor workspace files, local environment overrides, debug logs, experimental patches stashed away, etc.
Adding these to .gitignore pollutes the shared repository — every team member gets the exclusion, even though the files are irrelevant or private to one person. Editing .git/info/exclude manually requires dropping into the terminal, finding the file in Finder, or navigating Forks file tree to a hidden .git directory — all friction that breaks flow.
Proposed Solution
Add contextual UI actions that write entries to .git/info/exclude (the per-repo local exclusion file):
| Action |
Where |
What it does |
| "Exclude file locally" |
Right-click on an untracked file in the Changes view |
Appends the file path to .git/info/exclude and immediately removes it from the untracked list |
| "Exclude folder locally" |
Right-click on an untracked folder |
Appends folder_name/ to .git/info/exclude |
| "Exclude pattern locally" |
Right-click → a sub-option that opens an inline editor pre-filled with the file path, letting the user tweak it into a glob pattern before saving |
Full pattern flexibility (e.g. *.log, build/*) |
| "Edit .git/info/exclude…" |
Fork menu → Repository (or a gear icon in Changes view) |
Opens the file in Forks built-in editor (or the system default editor) |
Why .git/info/exclude (not global .config/git/ignore)
Per-repo exclusion is the right default for most cases:
- A file that is irrelevant in this repo may be meaningful in another.
- Stash entries that should be hidden in one project may need to appear elsewhere.
- The exclusion is automatically cleaned up when the repo is deleted — no orphaned global rules.
A follow-up could add a global ignore option too (#688 covers that), but the per-repo UI is the more immediate pain point.
Use Cases
- Local scratch/notes files: You create
notes.md or debug.log while investigating a bug. You want them tracked by git? No. You want them visible in Forks Changes view cluttering the diff? No. → "Exclude file locally."
- Stashed experimental work you want to keep out of sight: You have a stash that touches files you dont want to see in the working tree. → "Exclude pattern locally."
- IDE/editor files that differ per machine:
.vscode/settings.json with machine-specific paths. → Folder-level exclude.
- Build/test artifacts that fall outside
.gitignore: e.g. a test_output/ directory generated by a script you wrote for yourself.
Existing Related Issue
#688 covers global gitignore (~/.config/git/ignore). This request is complementary — it targets the per-repo .git/info/exclude file, which is a different mechanism with different scope and trade-offs.
Implementation Notes
- Fork already has access to the repo path and can read/write
.git/info/exclude via the embedded git (or directly as a text file).
- The file format is identical to
.gitignore — same pattern syntax, same rules.
- No git command is needed to apply the exclusion — git reads
.git/info/exclude automatically on the next git status.
- A "Reveal in Finder" button next to the Exclude actions would help users who want to manually edit the file further.
Would love to hear thoughts from the team and the community!
Problem
When working on a project, developers often create local-only files that should never be committed: personal scripts, IDE/editor workspace files, local environment overrides, debug logs, experimental patches stashed away, etc.
Adding these to
.gitignorepollutes the shared repository — every team member gets the exclusion, even though the files are irrelevant or private to one person. Editing.git/info/excludemanually requires dropping into the terminal, finding the file in Finder, or navigating Forks file tree to a hidden.gitdirectory — all friction that breaks flow.Proposed Solution
Add contextual UI actions that write entries to
.git/info/exclude(the per-repo local exclusion file):.git/info/excludeand immediately removes it from the untracked listfolder_name/to.git/info/exclude*.log,build/*)Why
.git/info/exclude(not global.config/git/ignore)Per-repo exclusion is the right default for most cases:
A follow-up could add a global ignore option too (#688 covers that), but the per-repo UI is the more immediate pain point.
Use Cases
notes.mdordebug.logwhile investigating a bug. You want them tracked by git? No. You want them visible in Forks Changes view cluttering the diff? No. → "Exclude file locally.".vscode/settings.jsonwith machine-specific paths. → Folder-level exclude..gitignore: e.g. atest_output/directory generated by a script you wrote for yourself.Existing Related Issue
#688 covers global gitignore (
~/.config/git/ignore). This request is complementary — it targets the per-repo.git/info/excludefile, which is a different mechanism with different scope and trade-offs.Implementation Notes
.git/info/excludevia the embedded git (or directly as a text file)..gitignore— same pattern syntax, same rules..git/info/excludeautomatically on the nextgit status.Would love to hear thoughts from the team and the community!