-
-
Notifications
You must be signed in to change notification settings - Fork 844
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
Ambiguity in piped vs not piped output #1046
Comments
Right, this was kind of discussed in #760, but not emphasized too much. I'm very sympathetic to this: $ fd pattern
a/path/matching/pattern
$ fd pattern | grep '^a/path'
$ # ??? See #362 for previous discussion about a config file. Right now there isn't one. A shell alias might be the best alternative. |
I also agree. This is not good. Do we want to change the behavior (again)? I'd hate to include the In the past, I have strictly argued against a config file for |
My preference would be to disable the I would keep the leading |
That sounds like a very good idea. It would be (another) breaking change, but I think I'm also in favor of doing that. FYI: @jcaplan @ykonstant1 |
At least it's only breaking for one or two releases? |
That seems ok to me too. |
What version of
fd
are you using?[paste the output of
fd --version
here]A short journey:
I am confused on why piped vs not piped output is different
Hmmm... Do I have other `.editorconfig` files I can reference for my new one?$ fd .editorconfig $
WAT? 😕
(5 minutes) ... aaaah, okay, it's a hidden file, and hidden files are not searched by default:
😵 ... but hey, if I look closer, there are paths that start with a dot (i.e. are hidden), and therefore "not mine". How about ...
$ fd -H .editorconfig | grep -vP '^\.' $
WAT? 🤯
(15 minutes later) ...
I maybe get the reasoning behind this option, however, I think it's counter-intuitive (for me) to not be able to parse things the way I am seeing them (unless I specifically
-print
,-print0
, etc ...).Is there any way I can reconcile things for myself?
It seems that
--strip-cwd-prefix
helps me do what I want, but then it's annoying to remember to type that as well all the time (and then-H
, and then sometimes--glob
etc) ...Is there a config file that I can use for this purpose (instead of an alias hidden somewhere)?
The text was updated successfully, but these errors were encountered: