Mail Archives: cygwin/2006/10/26/11:35:52
> There are a few other things to think about with your initial attempt.
> Right now, igncr is an all or nothing setting, can be inherited into child
> processes via SHELLOPTS, but can only be changed by explicit user action.
> Your patch only ever turns it on without user intervention, not off. You
> are changing the global igncr variable even though you described your goal
> as a per-file setting; so if bash reads two files in a row, first with
> \r\n, and the second with \n only, the second inherits the fact that the
> first decided to turn on igncr. At which point, why not just make igncr
> the default to begin with? So it sounds like the effort to make a
> per-file decision work correctly is getting bigger and bigger, with less
> and less perceivable benefits.
I see, I misunderstood the behavior of shell options like that, I thought it
only applied to the current bash process. It would be straightforward just to
create a new global variable instead of using igncr, and to handle your other
points, but in any case it sounds like you have made an effort to keep bash
POSIX compliant, and we should just respect that behavior and rely on setting
igncr as the default.
-lewis
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
- Raw text -