Closed robinbowes closed 7 years ago
That's because RCS directories are ignored by ack. RCS is a version control system, even though it might not be why you have a directory called RCS.
Unfortunately there's not a mechanism to tell ack to NOT ignore that RCS directory. :-(
I'm afraid I'm not very good at deciphering GIFs. I can imagine at least two different things that you're trying to convey, but I'd rather not guess.
Has Robin inadvertently collided with ancient ./RCS/ directory by up-casing a Kubernetes ./rcs/ replication directory ?
Supporting a --no-ignore-dir=RCS
override would be appropriate
I concur that https://github.com/petdance/ack3/issues/75 is the right way forward.
You can use --ignore-ack-defaults
right now.
I could, yes. But I think this is more a failure of expectation than any real problem with ack
.
I mean, does anyone still use RCS??
I mean, does anyone still use RCS??
I don't know, do they?
I mean, does anyone still use RCS??
If you can provide some sort of authoritative answer to this question, it would be helpful. Otherwise we're just guessing.
One of my use-cases for ack is inspecting legacy source code trees of new clients. We clean up legacy spaghetti-spills. I could find RCS, SCCS, or CVS, or all three in one place if they've not cleaned up previously! Current new client is still using CVS but agrees we can use Git for the assignment and migrate rest of their stuff as we get to it ! This is a win. A recent client had at least moved up to SVN ... so running across RCS in the wild is possible. Maybe it won't be in use and can be rm'd, but I may indeed want to ack
through a read-only tree. But ./RCS
is not as unique as ./.git/
since not hidden, and hardly a unique acronym, so maybe dropping automagic DWIMery for RCS
in ack3 and letting me add --ignore-dir=RCS
when i find it is better DWIM.
OTOH, --no-ignore-dir=
should also be able to override any built-in, for orthogonal-ness. Even if --no-ignore-dir=.git
is inefficient compared to find ~ -path \*/.git/config -print0 | xargs -0 ack 'url ='
it should be allowed.
The only valid data point you can take from this is that I was surprised that ack ignored the directory named RCS.
It's your call how significant you feel this is.
So, I noticed today that ack is not finding some matches in a directory tree that it should be finding.
For example:
Same search, with grep -R:
Same search with ag:
This is ack 2.18, installed on OSX using Homebrew.