[darcs-devel] Re: [darcs-users] darcs push problem: cannot find file

David Roundy droundy at abridgegame.org
Mon Nov 22 03:15:44 PST 2004


On Sun, Nov 21, 2004 at 11:45:04PM -0700, Will wrote:
> David Roundy <droundy at abridgegame.org> writes:
> > On Sun, Nov 21, 2004 at 12:32:03AM -0700, Will wrote:
> >> David Roundy <droundy at abridgegame.org> writes:
> >> > On Fri, Nov 19, 2004 at 10:41:08AM -0700, Will wrote:
> >> >>
> >> >> One ramification of this change is that when you enter the patch name
> >> >> interactively from cmd.exe it seems to contain a '\r', should it be
> >> >> stripped?
> >> >
> >> > Yeah, I don't think we want to allow '\r' in patch names.  Can you
> >> > submit a patch for this?
> >> 
> >> The same problem will happen with other input, so I guess we'd have to
> >> replace every call to 'getLine' with a similar function that strips
> >> '\r' too?
> >
> > Yeah, that makes sense.  Bonus points if we can do it in a way that
> > costs zero on non-windows systems... perhaps the C preprocessor is our
> > friend here.  Not that it'll cost much in any case, but still, as a
> > matter of principle...
> 
> I'll tackle this, but it may take a little while as I'm short on free
> time just now.  Do you want to remove the "set stdin and stdout to binary
> mode" patch, so people don't get into trouble with '\r's in their
> repositories?  The patch itself has one in the name already...

Technically '\r's in the patch names shouldn't cause trouble, although it's
not pleasant.  Perhaps we should bounce this feature idea off darcs-devel,
if you don't have time right now? It's an easy enough task for quite a new
darcs developer, and even a new haskell developer... although it's best
done by a windows user whose getLine actually shows this problem of the
extra '\r'.

I've decided to cc this to the -devel list in the hope that someone will
volunteer...
-- 
David Roundy
http://www.darcs.net




More information about the darcs-devel mailing list