Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-02 Thread Brian Inglis
On 2017-03-02 11:45, Eric Blake wrote: > On 03/02/2017 11:28 AM, Brian Inglis wrote: >> summary of checkbashisms -f run on 140 POSIX shell scripts as >> identified by file in my Cygwin 64 /bin/ with 784 packages (about >> 20% of cygwin-pkg-maint, 8% of setup.ini) installed, 70 possible >> issues

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-02 Thread Eric Blake
On 03/02/2017 11:28 AM, Brian Inglis wrote: > summary of checkbashisms -f run on 140 POSIX shell scripts as > identified by file in my Cygwin 64 /bin/ with 784 packages (about 20% > of cygwin-pkg-maint, 8% of setup.ini) installed, 70 possible issues > (some from wrapped scripts because of -f):

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-02 Thread Achim Gratz
Eric Blake writes: > To reiterate my answer in different terms: > > If you can convince Fedora to switch /bin/sh to dash, then I will > immediately follow in Cygwin. Until then, I'm worried that there are > enough scripts in the wild that use bashisms and will therefore break if > /bin/sh is not

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-02 Thread Brian Inglis
On 2017-03-02 07:29, Eric Blake wrote: > On 03/02/2017 07:36 AM, Marco Atzeri wrote: >> On 02/03/2017 13:36, Steven Penny wrote: >>> On Wed, 1 Mar 2017 23:31:24, Vince Rice wrote: Then you haven't been paying attention. And I didn't even attempt to make an argument one way or the other,

RE: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-02 Thread Nellis, Kenneth (Conduent)
From: Eric Blake > ... > Until then, I'm worried that there are > enough scripts in the wild that use bashisms and will therefore break if > /bin/sh is not bash, even though that number has reduced somewhat since > Debian made their switch. > ... I was thinking of testing my scripts by changing

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-02 Thread Brian Inglis
On 2017-03-02 06:36, Marco Atzeri wrote: > On 02/03/2017 13:36, Steven Penny wrote: >> On Wed, 1 Mar 2017 23:31:24, Vince Rice wrote: >>> Then you haven't been paying attention. And I didn't even attempt >>> to make an argument one way or the other, except to say stop >>> arguing. The horse is

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-02 Thread Eric Blake
On 03/02/2017 07:36 AM, Marco Atzeri wrote: > On 02/03/2017 13:36, Steven Penny wrote: >> On Wed, 1 Mar 2017 23:31:24, Vince Rice wrote: >>> Then you haven't been paying attention. >>> And I didn't even attempt to make an argument one way or the other,=20 >>> except to say stop arguing. The horse

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-02 Thread Marco Atzeri
On 02/03/2017 13:36, Steven Penny wrote: On Wed, 1 Mar 2017 23:31:24, Vince Rice wrote: Then you haven't been paying attention. And I didn't even attempt to make an argument one way or the other,=20 except to say stop arguing. The horse is dead.= Perhaps you could link to a constructive,

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-02 Thread Steven Penny
On Wed, 1 Mar 2017 23:31:24, Vince Rice wrote: Then you haven't been paying attention. And I didn't even attempt to make an argument one way or the other,=20 except to say stop arguing. The horse is dead.= Perhaps you could link to a constructive, concrete idea against the change that someone

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-01 Thread Vince Rice
> On Mar 1, 2017, at 11:27 PM, Steven Penny wrote: > > On Wed, 1 Mar 2017 21:46:38, Vince Rice wrote: >> There are valid reasons (which several others have made) not to force others >> to use it. > > Have they though? I have not seen anyone save Eric (including you) make a > valid > argument

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-01 Thread Steven Penny
On Wed, 1 Mar 2017 21:46:38, Vince Rice wrote: There are valid reasons (which several others have made) not to force others to use it. Have they though? I have not seen anyone save Eric (including you) make a valid argument beyond "I like it the old way". -- Problem reports:

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-01 Thread Vince Rice
> On Mar 1, 2017, at 6:22 PM, Steven Penny wrote: > > On Wed, 1 Mar 2017 09:42:27, cyg Simple wrote: >> Oh but it is. We're discussing the bike shed named /bin/sh. >> One of the color names is bash the other is dash; it's still the same >> bike shed. > > I see, when you

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-01 Thread Steven Penny
On Wed, 1 Mar 2017 09:42:27, cyg Simple wrote: Oh but it is. We're discussing the bike shed named /bin/sh. One of the color names is bash the other is dash; it's still the same bike shed. I see, when you realize your argument does not hold water, you resort to name calling. Here are concrete

RE: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-01 Thread Matt Seitz (matseitz)
Personally, I would invoke a variation of Linus's attitude to breaking user space apps: the distribution should not break existing user's scripts, even if they are not following "the rules". If you want to speed up the scripts distributed by Cygwin, then I would suggest modifying those

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-03-01 Thread cyg Simple
On 2/28/2017 4:43 PM, Steven Penny wrote: > On Tue, 28 Feb 2017 15:52:15, cyg Simple wrote: >> Ironic that *you* should make the same argument for using #!/bin/bash as >> I've made to you about using #!/bin/dash. > > Its not the same argument: > Oh but it is. We're discussing the bike shed

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-28 Thread Steven Penny
On Tue, 28 Feb 2017 15:52:15, cyg Simple wrote: Ironic that *you* should make the same argument for using #!/bin/bash as I've made to you about using #!/bin/dash. Its not the same argument: - You are talking about people assuming Dash is /bin/sh - I am talking about people assuming Bash is

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-28 Thread cyg Simple
On 2/27/2017 7:51 PM, Steven Penny wrote: > On Tue, 28 Feb 2017 10:12:47, Duncan Roe wrote: >> "we" being you and who else? >> /bin/sh has been bash for a long time and I would prefer it stays that >> way. > > “That’s the way it’s always been done” is not a good reason to keep doing > something.

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-27 Thread Steven Penny
On Tue, 28 Feb 2017 10:12:47, Duncan Roe wrote: "we" being you and who else? /bin/sh has been bash for a long time and I would prefer it stays that way. “That’s the way it’s always been done” is not a good reason to keep doing something. /bin/sh has been defined for 20 years, and it is not

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-27 Thread Duncan Roe
On Sat, Feb 25, 2017 at 09:08:55AM -0800, Steven Penny wrote: > On Sat, 25 Feb 2017 11:46:08, cyg Simple wrote: > > If *your* script has a dependency to run using *dash* instead of *sh* > > then you _must_ use #!/bin/dash anyway. > > I think you have a fundamental misunderstanding of what Dash is.

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-27 Thread Steven Penny
On Mon, 27 Feb 2017 11:20:54, Csaba Raduly wrote: Nice strawman argument. You seem to assume that Dash implements nothing beyond POSIX (and hence anything that runs on dash must run on every other shell). This is not the case. Perhaps you should have read my full post. Here, let me quote

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-27 Thread Csaba Raduly
On Sat, Feb 25, 2017 at 6:08 PM, Steven Penny wrote: > On Sat, 25 Feb 2017 11:46:08, cyg Simple wrote: >> >> If *your* script has a dependency to run using *dash* instead of *sh* >> then you _must_ use #!/bin/dash anyway. > > > I think you have a fundamental misunderstanding of what Dash is. Dash

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-25 Thread Steven Penny
On Sat, 25 Feb 2017 11:46:08, cyg Simple wrote: If *your* script has a dependency to run using *dash* instead of *sh* then you _must_ use #!/bin/dash anyway. I think you have a fundamental misunderstanding of what Dash is. Dash is a minimal shell, similar to the "sh" defined by POSIX:

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-25 Thread Steven Penny
On Fri, 24 Feb 2017 08:43:30, Eric Blake wrote: But we are severely limited in volunteer manpower compared to Debian, and I suspect that 1) there won't be enough testers (we won't know the real impact until it is no longer experimental, but that is too late), and 2) even if testers are diligent,

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-25 Thread cyg Simple
On 2/23/2017 2:46 PM, Steven Penny wrote: > On Thu, 23 Feb 2017 20:38:08, Andrey Repin wrote: >> $ cat /etc/postinstall/zp_dash-as-bin-sh.dash >> #!/bin/dash > >> test ! -h /bin/sh.exe && { >> _f="$(mktemp /bin/sh.XX)" >> { >> mv /bin/sh.exe "$_f" >> ln -s /bin/dash.exe

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-24 Thread Brian Inglis
On 2017-02-24 07:32, Eric Blake wrote: > On 02/23/2017 05:44 PM, Steven Penny wrote: >> On Thu, 23 Feb 2017 12:59:27, Brian Inglis wrote: >>> Some people may continue to need or prefer using bash in POSIX >>> mode. >> You might know this already, but "Bash in POSIX mode" is not quite >> POSIX.

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-24 Thread Lee Dilkie
On 2/24/2017 9:43 AM, Eric Blake wrote: On 02/23/2017 10:57 PM, Steven Penny wrote: Or more likely, many people likely have pre-existing scripts wrongly written as #!/bin/sh but which use bash-ism rather than portable POSIX-specified shell However, I think it is worth the trouble. If

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-24 Thread Eric Blake
On 02/23/2017 10:57 PM, Steven Penny wrote: >> Or more likely, many people likely have pre-existing scripts wrongly >> written as #!/bin/sh but which use bash-ism rather than portable >> POSIX-specified shell > > However, I think it is worth the trouble. If you'd like, I can post experimental

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-24 Thread Eric Blake
On 02/23/2017 05:44 PM, Steven Penny wrote: > On Thu, 23 Feb 2017 12:59:27, Brian Inglis wrote: >> Some people may continue to need or prefer using bash in POSIX mode. > > You might know this already, but "Bash in POSIX mode" is not quite > POSIX. For > example, arrays are not defined by POSIX:

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Yaakov Selkowitz
On 2017-02-23 14:41, Eric Blake wrote: Or more likely, many people likely have pre-existing scripts wrongly written as #!/bin/sh but which use bash-ism rather than portable POSIX-specified shell (if it is portable, then bash vs. dash executing the script shouldn't matter - but as Debian found

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Steven Penny
On Thu, 23 Feb 2017 22:15:37, "Larry Hall (Cygwin)" wrote: Since making a change of this magnitude is going to be an undertaking, we should be sure we're going to see the intended benefits before enduring the pain such a change would bring, though hopefully that pain would be short-lived and/or

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Larry Hall (Cygwin)
On 02/23/2017 06:01 PM, Tony Kelman wrote: The big question remains, where this speed boost coming from? Is this a startup time? Or some internal slowness? Because in latter case, given your STC, this is a bash issue and should be reported upstream. Dunno what you meant by STC, but upstream is

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Larry Hall (Cygwin)
On 02/23/2017 06:01 PM, Tony Kelman wrote: The big question remains, where this speed boost coming from? Is this a startup time? Or some internal slowness? Because in latter case, given your STC, this is a bash issue and should be reported upstream. Dunno what you meant by STC, but upstream is

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Steven Penny
On Thu, 23 Feb 2017 12:59:27, Brian Inglis wrote: Some people may continue to need or prefer using bash in POSIX mode. You might know this already, but "Bash in POSIX mode" is not quite POSIX. For example, arrays are not defined by POSIX: http://mywiki.wooledge.org/Bashism#Arrays Yes Bash

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Andrey Repin
Greetings, Tony Kelman! >> The big question remains, where this speed boost coming from? >> Is this a startup time? Or some internal slowness? >> Because in latter case, given your STC, this is a bash issue and should be >> reported upstream. > Dunno what you meant by STC,

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Steven Penny
On Fri, 24 Feb 2017 00:50:08, Andrey Repin wrote: In fact, you should use specific shell name, if you want specific behavior. That is not at issue here. Both before and after this proposed change, I can use #!/bin/dash to explicitly call Dash and #!/bin/bash to explicitly call Bash. What _is_

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Vince Rice
> On Feb 23, 2017, at 5:04 PM, Eliot Moss wrote: > > On 2/23/2017 6:01 PM, Tony Kelman wrote: >>> The big question remains, where this speed boost coming from? >>> Is this a startup time? Or some internal slowness? >>> Because in latter case, given your STC, this is a bash

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Kenneth Wolcott
On Thu, Feb 23, 2017 at 3:04 PM, Eliot Moss wrote: > On 2/23/2017 6:01 PM, Tony Kelman wrote: >>> >>> The big question remains, where this speed boost coming from? >>> Is this a startup time? Or some internal slowness? >>> Because in latter case, given your STC, this is a bash

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Eliot Moss
On 2/23/2017 6:01 PM, Tony Kelman wrote: The big question remains, where this speed boost coming from? Is this a startup time? Or some internal slowness? Because in latter case, given your STC, this is a bash issue and should be reported upstream. Dunno what you meant by STC, Indeed, this

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Tony Kelman
> The big question remains, where this speed boost coming from? > Is this a startup time? Or some internal slowness? > Because in latter case, given your STC, this is a bash issue and should be > reported upstream. Dunno what you meant by STC, but upstream is well aware: $ man bash | tail -n 21

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Andrey Repin
Greetings, Steven Penny! > On Thu, 23 Feb 2017 20:38:08, Andrey Repin wrote: >> $ cat /etc/postinstall/zp_dash-as-bin-sh.dash >> #!/bin/dash >> test ! -h /bin/sh.exe && { >> _f="$(mktemp /bin/sh.XX)" >> { >> mv /bin/sh.exe "$_f" >> ln -s /bin/dash.exe /bin/sh.exe >> } || mv

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Eric Blake
On 02/23/2017 01:59 PM, Brian Inglis wrote: >> If script succeeds, then yes sh is now a symlink to Dash, but only >> for my system. I still have to use #!/bin/dash with my scripts, >> because otherwise people with Bash -> sh will not get the speed >> boost. The whole point of this thread is that

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Brian Inglis
On 2017-02-23 12:46, Steven Penny wrote: > On Thu, 23 Feb 2017 20:38:08, Andrey Repin wrote: >> $ cat /etc/postinstall/zp_dash-as-bin-sh.dash >> #!/bin/dash > >> test ! -h /bin/sh.exe && { >> _f="$(mktemp /bin/sh.XX)" >> { >> mv /bin/sh.exe "$_f" >> ln -s /bin/dash.exe /bin/sh.exe

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Steven Penny
On Thu, 23 Feb 2017 20:38:08, Andrey Repin wrote: $ cat /etc/postinstall/zp_dash-as-bin-sh.dash #!/bin/dash test ! -h /bin/sh.exe && { _f="$(mktemp /bin/sh.XX)" { mv /bin/sh.exe "$_f" ln -s /bin/dash.exe /bin/sh.exe } || mv "$_f" /bin/sh.exe rm "$_f" } exit 0 This is a

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-23 Thread Andrey Repin
Greetings, Steven Penny! > On Fri, 17 Feb 2017 07:50:34, "Eric Blake (cygwin)" wrote: >> For now, there are no immediate plans of replacing /bin/sh >> with dash, but the possibility remains for the future. > I am a fan of this. $ cat /etc/postinstall/zp_dash-as-bin-sh.dash #!/bin/dash test !

Re: [ANNOUNCEMENT] Updated: dash-0.5.9.1-1

2017-02-22 Thread Steven Penny
On Fri, 17 Feb 2017 07:50:34, "Eric Blake (cygwin)" wrote: For now, there are no immediate plans of replacing /bin/sh with dash, but the possibility remains for the future. I am a fan of this. Debian does this already, and it would dramatically speed up shell scripts: $ cat alfa.sh