Re: Unresolved issues
- From
Linus Torvalds <torvalds@linux-foundation.org>
- Date
- Feb 21, 2007, 02:03 UTC
- Message-ID
- <Pine.LNX.4.64.0702201758560.4043@woody.linux-foundation.org>
- In-Reply-To
- <alpine.LRH.0.82.0702202003370.31945@xanadu.home>
On Tue, 20 Feb 2007, Nicolas Pitre wrote:
Show 16 quoted lines
> > I think this is not generic enough. For one thing this should not be > used for crlf only. There is also the binary patch generation code that > wants to know if a file is binary or not. > > What about: > > [filetype "text"] > match=*.[ch] > attribute=text > crlfmangle=true > > [filetype "images"] > match=*.jpg > attribute=binary > merge=special_jpg_merger
Yes, that's a much nicer format - both more readable, and more generic.
Although I'd just suggest skipping the "crlfmangle". Just document the fact that for "attribute=text", we mangle line-endings as per the rules defined elsewhere (which is possibly different for input/output in addition for the normal unix/windows rule changes)
And then you can just have multiple "match=" rules, so that you don't need to make one complex one.
Linus