Re: Bug#783826: cloud-utils growroot doesn't work with newer sfdisk >= 2.26 : fixed patch solution for newer and older sfdisk
- To: Scott Moser <scott.moser@canonical.com>, 783826@bugs.debian.org
- Cc: Thomas Goirand <thomas@goirand.fr>, Juerg Haefliger <juerg.haefliger@hp.com>, Tracking bugs and development for OpenStack <openstack-devel@lists.alioth.debian.org>, debian-cloud@lists.debian.org, Julien Danjou <acid@debian.org>
- Subject: Re: Bug#783826: cloud-utils growroot doesn't work with newer sfdisk >= 2.26 : fixed patch solution for newer and older sfdisk
- From: Antonio Terceiro <terceiro@debian.org>
- Date: Mon, 4 May 2015 17:18:04 -0300
- Message-id: <[🔎] 20150504201804.GA5872@debian.org>
- Mail-followup-to: Antonio Terceiro <terceiro@debian.org>, Scott Moser <scott.moser@canonical.com>, 783826@bugs.debian.org, Thomas Goirand <thomas@goirand.fr>, Juerg Haefliger <juerg.haefliger@hp.com>, Tracking bugs and development for OpenStack <openstack-devel@lists.alioth.debian.org>, debian-cloud@lists.debian.org, Julien Danjou <acid@debian.org>
- In-reply-to: <[🔎] alpine.DEB.2.02.1505041018300.3045@brickies>
- References: <[🔎] 554770FA.8000502@goirand.fr> <[🔎] alpine.DEB.2.02.1505041018300.3045@brickies>
On Mon, May 04, 2015 at 12:48:37PM -0400, Scott Moser wrote:
> > Also, what about the do-not-use-EXIT-when-trapping.patch patch which I had to
> > add in Debian? Could you please apply them both?
>
> EXIT is posix compatible. you really should change the shell to be posix
> compatible rather than changing all programs to expect a subset of poxix
> shell.
> http://pubs.opengroup.org/onlinepubs/000095399/utilities/trap.html
EXIT is supported by dash ... I have just tested the script below and it
works as expected on all Debian release since at least wheezy.
----------------8<----------------8<----------------8<-----------------
$ cat /tmp/test
#!/bin/sh
cleanup() {
echo "exiting ..."
}
trap cleanup EXIT
$ for release in wheezy jessie sid; do echo $release; schroot -c $release /tmp/test; done
wheezy
exiting ...
jessie
exiting ...
sid
exiting ...
----------------8<----------------8<----------------8<-----------------
--
Antonio Terceiro <terceiro@debian.org>
Attachment:
signature.asc
Description: Digital signature
Reply to: