From: Nguyen Thai Ngoc Duy Date: Tue, 18 Aug 2009 14:35:05 GMT Subject: Re: git find (was: [RFC PATCH v3 8/8] --sparse for porcelains) Message-ID: In-Reply-To: <200908180825.55289.jnareb@gmail.com> On Tue, Aug 18, 2009 at 1:25 PM, Jakub Narebski wrote: > Well, I also think that it would be nice and useful to have "git find" > in addition to current "git grep". Can you make a draft on how you want "git find" to be? Except the "-exec" part, Git allows us to search using various commands (ls-files, rev-list, log). I don't think a single "git find" can cover them all. I was thinking about putting more find-options to search commands we already have. ls-files would support -exec, for example. A few things that I'd love to have supported: - --depth for ls-files (probably all pathspec-as-argument commands) - logical combination of search criteria - unified blob locator. git-show understands SHA-1:/path/to/blob syntax. What if git-log can output using similar syntax, then feed them to git-grep in order to grep through (across commits)? -- Duy