vscode-spell-checker
vscode-spell-checker copied to clipboard
git worktree support for .gitignore
I have been using git worktrees with the following setup:
- outer_repository
- .git (folder)
- .gitignore
- inner_repository
- worktrees
- branch_1
- inner_repository
- .git (worktree pointer)
- spellchecker_target
The outer_repository .gitignore contains /worktrees, which matches the spellchecker_target; however the spellchecker_target is not gitignored in inner_repository. However, vscode-spell-checker fails to check the file: File is exclude by .gitignore.
This works fine when I use a regular, non-worktree clone of the repository. But I would like to use worktree since my .git folder is rather huge.
Looks like this repository uses cspell-gitignore to determine whether a file is gitignored. This package doesn't seem to stop when a .git
file or directory is found, which is causing the issue.
Perhaps a better question is: why does gitignore determine whether or not we spellcheck files? Why not just spellcheck every file regardless of .gitignore?
In fact there is a setting called useGitignore
that you can turn off, which will fix your problem.
Fair, thanks!
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.