Re: -i option of set missing in man bash

2015-03-20 Thread Chet Ramey
On 3/16/15 4:30 PM, Eduardo A. Bustamante López wrote: >> Here's the other side: allowing `set -$-' to succeed keeps a Posix-mode >> shell running a script from throwing a fatal error. Allowing it also >> keeps the bug reports down. The same rationale can be used to add -c and >> -s to the no-op

Re: -i option of set missing in man bash

2015-03-16 Thread Eduardo A . Bustamante López
> Here's the other side: allowing `set -$-' to succeed keeps a Posix-mode > shell running a script from throwing a fatal error. Allowing it also > keeps the bug reports down. The same rationale can be used to add -c and > -s to the no-op flags, since those are command-line options that end up > i

Re: -i option of set missing in man bash

2015-03-16 Thread Chet Ramey
On 3/13/15 8:47 PM, Eduardo A. Bustamante López wrote: >> You can avoid these surprises by making -i just as other options, i.e., >> working within the shell not just when a shell is started. [..] > I don't think it's good to have set +/-i available after initialization. It's > more complex to hand

Re: -i option of set missing in man bash

2015-03-13 Thread Eduardo A . Bustamante López
> You can avoid these surprises by making -i just as other options, i.e., > working within the shell not just when a shell is started. [..] I don't think it's good to have set +/-i available after initialization. It's more complex to handle, and with little (or null?) gain. If you're using set -i i

Re: -i option of set missing in man bash

2015-03-13 Thread Peng Yu
On Friday, March 13, 2015, Chet Ramey wrote: > On 3/12/15 2:13 PM, Peng Yu wrote: > >>> The -i option obviously works with set. But it is missing in the man > >>> page. Should this be added? > >> > >> No. It's really only there for completeness, so things like `set $-' > >> work as expected with

Re: -i option of set missing in man bash

2015-03-13 Thread Chet Ramey
On 3/12/15 2:13 PM, Peng Yu wrote: >>> The -i option obviously works with set. But it is missing in the man >>> page. Should this be added? >> >> No. It's really only there for completeness, so things like `set $-' >> work as expected without error. > > But if something is in the implementation,

Re: -i option of set missing in man bash

2015-03-12 Thread Peng Yu
On Thu, Mar 12, 2015 at 1:29 PM, Greg Wooledge wrote: > On Thu, Mar 12, 2015 at 01:13:18PM -0500, Peng Yu wrote: >> One may want to manually set -i option in a bash script for whatever >> reason. (In this case, it is to check COLUMNS.) > > http://mywiki.wooledge.org/BashFAQ/091 This does not work

Re: -i option of set missing in man bash

2015-03-12 Thread Greg Wooledge
On Thu, Mar 12, 2015 at 01:13:18PM -0500, Peng Yu wrote: > One may want to manually set -i option in a bash script for whatever > reason. (In this case, it is to check COLUMNS.) http://mywiki.wooledge.org/BashFAQ/091

Re: -i option of set missing in man bash

2015-03-12 Thread Peng Yu
>> The -i option obviously works with set. But it is missing in the man >> page. Should this be added? > > No. It's really only there for completeness, so things like `set $-' > work as expected without error. But if something is in the implementation, it should be also in the documentation, righ

Re: -i option of set missing in man bash

2015-03-12 Thread Chet Ramey
On 3/11/15 6:59 PM, Peng Yu wrote: > Hi, > > The -i option obviously works with set. But it is missing in the man > page. Should this be added? No. It's really only there for completeness, so things like `set $-' work as expected without error. The -s option does the same thing, for example. -

-i option of set missing in man bash

2015-03-11 Thread Peng Yu
Hi, The -i option obviously works with set. But it is missing in the man page. Should this be added? ~$ echo $- himBH ~$ set +i ~$ echo $- hmBH The following lines are from the man page. set [--abefhkmnptuvxBCEHPT] [-o option-name] [arg ...] set [+abefhkmnptuvxBCEHPT] [+o option-n