-
-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Whitelisting via .gitignore does not handle dot prefix ("!./fname") #1374
Comments
I just tried this, and my
does not show the
does show it.
Even when my .gitignore simply contains:
the test file is NOT being git-ignored. Are we sure that the |
@blueyed Can you clarify what you meant by "git handles this as expected" in your initial bug report here? |
IMHO this is the expected behavior https://git-scm.com/docs/gitignore
the dot
"It is not possible to re-include a file if a parent directory (in this case Furthermore: If you specify this .gitignore
$ tree -a
.
├── foo
│ └── bar
└── .gitignore Then $ git status
On branch master
No commits yet
nothing to commit (create/copy files and use "git add" to track) |
Closing as not a bug. Happy to revisit with more compelling data. |
Given a
.gitignore
file:rg
will skip thePKGBUILD
file:This appears to be due to the leading dot there.
Git handles this as expected.
Removing the dot (using
!/PKGBUILD
) whitelists it then:What version of ripgrep are you using?
ripgrep 11.0.2
The text was updated successfully, but these errors were encountered: