From owner-freebsd-questions@FreeBSD.ORG Sat Oct 11 23:55:23 2014 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id A26B84AD for ; Sat, 11 Oct 2014 23:55:23 +0000 (UTC) Received: from mail.cyberleo.net (paka.cyberleo.net [216.226.128.180]) by mx1.freebsd.org (Postfix) with ESMTP id 811F8999 for ; Sat, 11 Oct 2014 23:55:22 +0000 (UTC) Received: from [172.16.44.4] (vitani.den.cyberleo.net [216.80.73.130]) by mail.cyberleo.net (Postfix) with ESMTPSA id A699F1464D; Sat, 11 Oct 2014 19:48:33 -0400 (EDT) Message-ID: <5439C1D0.6030902@cyberleo.net> Date: Sat, 11 Oct 2014 18:48:32 -0500 From: CyberLeo Kitsana User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.8.0 MIME-Version: 1.0 To: "William A. Mahaffey III" , FreeBSD Questions Subject: Re: sh man page .... References: <5437FB8B.9080008@hiwaay.net> In-Reply-To: <5437FB8B.9080008@hiwaay.net> X-Enigmail-Version: 1.6 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 11 Oct 2014 23:55:23 -0000 On 10/10/2014 10:30 AM, William A. Mahaffey III wrote: > > > I have a FBSD 9.3 desktop that supplanted a Linux FC14 desktop used for > web access, some light development, & other day-to-day tasks (i.e. my > daily driver, so to speak). I had a bunch of shell scripts written to > use Linux sh, which was in fact bash, which means it had a superset of > the arithmetic operators that traditional sh had. When I use these > scripts under sh under FBSD 9.3, they largely work, though there are > some minor differences (empty strings evaluate to zero (0) under bash, > error under sh). The man page for sh doesn't reflect some of these > compatibilities/incompatibilities, & is a bit short on its description > of arithmetic evaluations in general. It would be sweet if it were > updated to document more of the differences/similarities w/ bash, since > there a clearly a decent number of similarities, & only a few (for me) > differences. TIA .... Try running devel/checkbashisms against the scripts. It's something Debian uses to ease migration from Bash to Dash in their base system, and I've found it rather useful to ensure no bashisms sneak into my own portable scripts. -- Fuzzy love, -CyberLeo Technical Administrator CyberLeo.Net Webhosting http://www.CyberLeo.Net Furry Peace! - http://www.fur.com/peace/