monotone-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Monotone-devel] Re: Looking at the code affected in bug 9752 leaves


From: Jon Bright
Subject: Re: [Monotone-devel] Re: Looking at the code affected in bug 9752 leaves a weird taste...
Date: Wed, 18 Aug 2004 15:18:20 +0200
User-agent: Mozilla Thunderbird 0.6 (Windows/20040502)

Hi,

I agree we're now saying more or less the same thing.

Richard Levitte - VMS Whacker wrote:

jon> Wouldn't a --type=[text|text-alwayslf|text-alwayscrlf|binary]
jon> parameter be easier for all concerned?

--type=[text|binary], IMHO.

...except for this point. I think I'm probably restating what Bruce already said, but you do need to be able to override use of local line conventions on text files. You need to be able to do this on a monotone/system-wide basis, presumably via a hook, and you need to be able to do it on a per-file basis.

Reasons for doing this on a monotone/system-wide basis are things such as checking out onto a Samba share or so on a Linux box. The share's going to be used by Windows clients and hence you want CR+LF, but the system line ending is LF. Similar scenarios occur for things like checking out before using Wine, or (my personal favourite) checking out in Windows ready to use in Linux on a dual-boot system (my laptop's dual boot, but because Broadcom were kind enough not to publish specs for my wireless LAN card, only Windows has network access). The systemwide override is certainly less common and used for more esoteric things, but I think at the cost of a hook, it's worth it.

On a per-file basis:

a) some standards presumably specify a line-ending for a file - it then always wants to be checked out with that line-ending, otherwise the VC system's caused you to violate the standard

b) some tools are broken and only work with one or the other line ending (I believe there are several affected MS tools, and I recall seeing problems with Borland Builder with CVS checking out its project files using CR+LF because it was on Windows, but Builder having written them with LF-only and expecting to get them back in that format)

c) you're checking out text files which have CR+LF conventions (so that Windows Notepad doesn't screw them up) onto a website hosted on a Linux box.

d) I could probably come up with more examples, but you get the idea...

--
Jon Bright
Silicon Circus Ltd.
http://www.siliconcircus.com




reply via email to

[Prev in Thread] Current Thread [Next in Thread]