Re: [PATCH 11/16] config: add --literal-match option
- From
Jeff King <peff@peff.net>
- Date
- Mar 13, 2008, 13:24 UTC
- Message-ID
- <20080313132419.GA28564@coredump.intra.peff.net>
- In-Reply-To
- <fr9ivq$eh0$1@ger.gmane.org>
On Wed, Mar 12, 2008 at 10:46:43PM +0100, Jakub Narebski wrote:
Show 9 quoted lines
> > +--literal-match:: > > + > > + Some invocations of git-config will limit their actions based on > > + matching a config value to a regular expression. If this option > > + is used, then any such matches are done as a string comparison > > + rather than as a regular expression match. > > + > > Why this option is not named --fixed-strings, as everywhere else, then?
Because I never use --fixed-strings anywhere else and didn't think of it? :)
I think, though, that there is a key difference, and using that name would lead to confusion. In grep, --fixed-strings means "find this fixed _substring_ within the input" whereas this option means "find the value that is byte-for-byte equal to this."
-Peff