Re: why does errexit exist in its current utterly useless form?

2012-12-15 Thread matei . david
On Saturday, December 15, 2012 5:23:04 PM UTC-5, Chet Ramey wrote: > There is already a proposal for a new option similar to what you want; you > can read the discussion at > > http://austingroupbugs.net/view.php?id=537 Thank you for all the references, I'll have a look!

Re: Trap variable scope

2012-12-15 Thread Chet Ramey
On 11/2/12 10:48 AM, Nikolai Kondrashov wrote: > Hi everyone, > > I've encountered a very strange behavior regarding variable scope and traps, > which looks very much like a bug. This will be fixed, to the extent that identical blocks of code like the two below will do the same thing, in the next

Re: loadable support for HP-UX 10 (bash 4.2)

2012-12-15 Thread Chet Ramey
On 10/5/12 9:19 AM, Greg Wooledge wrote: > Here's an updated version of a patch I did a few years ago to add loadable > support for bash under HP-UX 10. The previous patch was for bash 4.0. > This one has been updated for bash 4.2. It is fundamentally the same > patch, just with different context

Re: Requesting an alternate nameref feature

2012-12-15 Thread Chet Ramey
On 12/12/12 1:04 PM, Dan Douglas wrote: > Hello. Could we possibly modify or create an additional variant of "typeset > -n" > which produces "real" references rather than just dynamic references by name? > In other words, I'd like to be able to create reference variables that always > point to the

Re: Questions to bash "read" builtin functionality

2012-12-15 Thread Chet Ramey
On 12/14/12 6:28 AM, Fiedler Roman wrote: > Hello list, > > One of our bash-scrips failed with very low frequency but randomly. The > result was that exactly 1 byte was lost, so the string returned by "read -t > 1" was too short. The culprit seems to be the built-in read function itself, > the

Re: why does errexit exist in its current utterly useless form?

2012-12-15 Thread Chet Ramey
On 12/15/12 11:54 AM, matei.da...@gmail.com wrote: > On Friday, December 14, 2012 6:23:41 PM UTC-5, Eric Blake wrote: >> Short answer: historical compatibility. 'set -e' has been specified to >> behave the way it did 30 years ago in one reference implementation, and >> while you can argue till you

Re: shouldn't /+(??) capture 2 letter files only?

2012-12-15 Thread DJ Mills
On Sat, Dec 15, 2012 at 1:01 PM, gregrwm wrote: > >> > echo !(??|foo|bar) > >> > >> precisely where i started this thread, !(??) > > > > +(??) and !(??) are completely different things. !(??) was never > mentioned in the original question, and should work as expected. > > yow, truly, you're saying

Re: shouldn't /+(??) capture 2 letter files only?

2012-12-15 Thread gregrwm
>> > echo !(??|foo|bar) >> >> precisely where i started this thread, !(??) > > +(??) and !(??) are completely different things. !(??) was never mentioned in the original question, and should work as expected. yow, truly, you're saying +(??) selects *any multiple* of 2chars, but !(??) excludes 2cha

Re: why does errexit exist in its current utterly useless form?

2012-12-15 Thread matei . david
On Friday, December 14, 2012 6:23:41 PM UTC-5, Eric Blake wrote: > Short answer: historical compatibility. 'set -e' has been specified to > behave the way it did 30 years ago in one reference implementation, and > while you can argue till you are blue in the face that the reference > implementatio