This is the mail archive of the
mailing list for the Cygwin project.
Re: Inconsistency in find ... -name ...
Eric Blake wrote:
I've wondered about this. Does bash special case the find command then?
Which other commands does is special case like this?
echo is your friend. Try:
Using find, I didn't protect spec in -name (-name 'spec') in a couple of
instances but they still worked, viz-a-viz:
$ find /home/lowella -type f -name *.h
whereas a couple of others didn't work, viz-a-viz:
$ find /home/lowella -type f -name *.txt
find: paths must precede expression
Usage: find [-H] [-L] [-P] [path...] [expression]
$ echo /home/lowella -type f -name *.h
And notice that since there are no .h files in the current
directory, the shell passes the glob through unchanged
to find. You can also do 'shopt -s nullglob' to change that.
Don't tell anyone, but duct tape is The Force. It has a dark side, and a
light side, and it binds the Universe together.
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html