Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-15 Thread Daniel P. Berrange
On Mon, Apr 14, 2014 at 11:26:17AM -0500, Ben Nemec wrote: tldr: I propose we use bash explicitly for all diskimage-builder scripts (at least for the short-term - see details below). This is something that was raised on my linting changes to enable set -o pipefail. That is a bash-ism, so it

Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-15 Thread Chris Jones
Hi On 15 April 2014 09:14, Daniel P. Berrange berra...@redhat.com wrote: I supose that rewriting the code to be in Python is out of the question ? IMHO shell is just a terrible language for doing any program that is remotely complicated (ie longer than 10 lines of I don't think it's out of

Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-15 Thread Ghe Rivero
+1 to use bash as the default shell. So far, all major distros use bash as the default one (except Debian which uses dash). An about rewriting the code in Python, I agree that shell is complicated for large programs, but writing anything command oriented in other than shell is a nightmare. But

Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-15 Thread Petr Blaho
On Mon, Apr 14, 2014 at 07:24:57PM +0100, Chris Jones wrote: Hi Apart from special cases like the ramdisk's /init, which is a script that needs to run in busybox's shell, everything should be using bash. There's no point us tying ourselves in knots trying to achieve POSIX compliance for

Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-15 Thread Ryan Brady
- Original Message - From: Chris Jones c...@tenshu.net To: openst...@nemebean.com, OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org Sent: Monday, April 14, 2014 2:24:57 PM Subject: Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-15 Thread Jay Dobies
+1 to using bash, the argument about not keeping POSIX compliance for the sake of it makes sense to me. On 04/15/2014 07:31 AM, Ghe Rivero wrote: +1 to use bash as the default shell. So far, all major distros use bash as the default one (except Debian which uses dash). An about rewriting the

Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-15 Thread Dougal Matthews
Another +1 for using bash. Sounds like an easy win. On 15/04/14 12:31, Ghe Rivero wrote: +1 to use bash as the default shell. So far, all major distros use bash as the default one (except Debian which uses dash). An about rewriting the code in Python, I agree that shell is complicated for large

Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-15 Thread Chmouel Boudjnah
FWIW: we are using bash in devstack if we were going to try to make it POSIX bourne shell (or whatever /bin/sh is) it would have been a huge pain. On Tue, Apr 15, 2014 at 1:25 PM, Dougal Matthews dou...@redhat.com wrote: Another +1 for using bash. Sounds like an easy win. On 15/04/14 12:31,

Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-15 Thread Clint Byrum
Excerpts from Ben Nemec's message of 2014-04-14 09:26:17 -0700: tldr: I propose we use bash explicitly for all diskimage-builder scripts (at least for the short-term - see details below). This is something that was raised on my linting changes to enable set -o pipefail. That is a

Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-15 Thread Clint Byrum
Excerpts from Ghe Rivero's message of 2014-04-15 04:31:19 -0700: +1 to use bash as the default shell. So far, all major distros use bash as the default one (except Debian which uses dash). An about rewriting the code in Python, I agree that shell is complicated for large programs, but writing

Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-15 Thread Ben Nemec
On 04/15/2014 02:44 PM, Clint Byrum wrote: Excerpts from Ben Nemec's message of 2014-04-14 09:26:17 -0700: tldr: I propose we use bash explicitly for all diskimage-builder scripts (at least for the short-term - see details below). This is something that was raised on my linting changes to

[openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-14 Thread Ben Nemec
tldr: I propose we use bash explicitly for all diskimage-builder scripts (at least for the short-term - see details below). This is something that was raised on my linting changes to enable set -o pipefail. That is a bash-ism, so it could break in the diskimage-builder scripts that are run

Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-14 Thread Doug Hellmann
As someone who maintains a shell-script project across several sh-like shells, I can say the edge cases cause enough work and testing hassles that you shouldn't undertake it lightly. Is there any particular need to run these tools under a non-bash shell? Doug On Mon, Apr 14, 2014 at 12:26 PM,

Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-14 Thread Ben Nemec
On 04/14/2014 11:53 AM, Doug Hellmann wrote: As someone who maintains a shell-script project across several sh-like shells, I can say the edge cases cause enough work and testing hassles that you shouldn't undertake it lightly. Is there any particular need to run these tools under a non-bash

Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-14 Thread Dan Prince
- Original Message - From: Ben Nemec openst...@nemebean.com To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org Sent: Monday, April 14, 2014 12:26:17 PM Subject: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh tldr: I propose we use

Re: [openstack-dev] [tripleo] /bin/bash vs. /bin/sh

2014-04-14 Thread Chris Jones
Hi Apart from special cases like the ramdisk's /init, which is a script that needs to run in busybox's shell, everything should be using bash. There's no point us tying ourselves in knots trying to achieve POSIX compliance for the sake of it, when bashisms are super useful. Cheers, Chris On