Re: [PATCH 2/3] Makefile: use `find` to determine static header dependencies
- From
Jonathan Nieder <jrnieder@gmail.com>
- Date
- Aug 25, 2014, 21:27 UTC
- Message-ID
- <20140825212705.GU20185@google.com>
- In-Reply-To
- <xmqqppfol1sx.fsf@gitster.dls.corp.google.com>
Junio C Hamano wrote:
> Jonathan Nieder <jrnieder@gmail.com> writes:
Show 22 quoted lines
>> Tiny nit: I might use >> >> $(shell $(FIND) * \ >> -name . -o >> -name '.*' -prune -o \ >> -name t -prune -o \ >> -name Documentation -prune -o \ >> -name '*.h' -print) >> >> or >> >> $(shell $(FIND) * \ >> -name '.?*' -prune -o \ >> -name t -prune -o \ >> -name Documentation -prune -o \ >> -name '*.h' -print) >> >> to avoid spending time looking in other dot-directories like .svn, >> .hg, or .snapshot. > > Wouldn't it be sufficient to start digging not from "*" but from > "??*"?
Gah, the * was supposed to be . in my examples (though it doesn't hurt).
> find ??* \( -name Documentation -o -name .\?\* \) -prune -o -name \*.h
Heh. Yeah, that would work. ;-)