From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from lists.gentoo.org ([140.105.134.102] helo=robin.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1Il4rz-00016F-Vn for garchives@archives.gentoo.org; Thu, 25 Oct 2007 15:43:40 +0000 Received: from robin.gentoo.org (localhost [127.0.0.1]) by robin.gentoo.org (8.14.1/8.14.0) with SMTP id l9PFge7Y021737; Thu, 25 Oct 2007 15:42:40 GMT Received: from mail.marples.name (rsm.demon.co.uk [80.177.111.50]) by robin.gentoo.org (8.14.1/8.14.0) with ESMTP id l9PFeYKL019138 for ; Thu, 25 Oct 2007 15:40:34 GMT Received: from [10.73.1.31] (uberlaptop.marples.name [10.73.1.31]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.marples.name (Postfix) with ESMTP id 11B85190100 for ; Thu, 25 Oct 2007 16:40:33 +0100 (BST) Subject: [gentoo-dev] Opinions Wanted - Arrays again :) From: Roy Marples To: gentoo-dev@lists.gentoo.org Content-Type: text/plain Organization: Gentoo Date: Thu, 25 Oct 2007 16:40:31 +0100 Message-Id: <1193326831.4245.16.camel@uberlaptop.marples.name> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@gentoo.org Reply-to: gentoo-dev@lists.gentoo.org Mime-Version: 1.0 X-Mailer: Evolution 2.12.1 Content-Transfer-Encoding: 7bit X-Archives-Salt: abff3a42-0bf2-4d9b-97c7-6aa61c293461 X-Archives-Hash: 5fbeba465313058239aeeb9a5611754a Hello List It's your favourite posix shell lover here, asking for your honest opinions. array="1.2.3.4 netmask 5.6.7.8; \* 'host.name' netmask 1.2.3.4 -I 'option; $FOO with spaces' " array=("1.2.3.4 netmask 5.6.7.8;" "\*" "'host.name' netmask 1.2.3.4" "-I 'option; $FOO with spaces'" ) array="'1.2.3.4 netmask 5.6.7.8;' \ '\*' \ \"'host.name' netmask 1.2.3.4\" \ \"-I 'option; $FOO with spaces'\" " The first and last are of course posix constructs whilst the middle is bash. The bash one is purely there for reference, and of course you can still use it if /bin/sh is bash. The last one is what baselayout-2 currently uses and I'm wondering if we should switch to the first one before we come out of package.mask. I'm asking which you think are the most readable of the first and last ones and if you see any issues with either. Thanks Roy -- gentoo-dev@gentoo.org mailing list