From owner-freebsd-questions@FreeBSD.ORG Thu Jun 24 02:00:02 2010 Return-Path: Delivered-To: questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 07BF5106566B for ; Thu, 24 Jun 2010 02:00:02 +0000 (UTC) (envelope-from thomas.keusch@bsd-solutions-duesseldorf.de) Received: from vs.gothschlampen.com (vs.gothschlampen.com [85.93.11.85]) by mx1.freebsd.org (Postfix) with ESMTP id BE36E8FC0A for ; Thu, 24 Jun 2010 02:00:01 +0000 (UTC) Received: by vs.gothschlampen.com (Postfix, from userid 667) id BB15D1D32F4; Thu, 24 Jun 2010 03:37:55 +0200 (CEST) Date: Thu, 24 Jun 2010 03:37:55 +0200 From: Thomas To: questions@freebsd.org Message-ID: <20100624013755.GA5009@gothschlampen.com> References: <4C22B3D7.6070102@comclark.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4C22B3D7.6070102@comclark.com> User-Agent: Mutt/1.5.13 (2006-08-11) Cc: Subject: Re: .sh check for numeric content X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jun 2010 02:00:02 -0000 On Thu, Jun 24, 2010 at 09:24:39AM +0800, Aiza wrote: Hello, > Receiving a variable from the command line that is suppose > to contain numeric values. > > How do I code a test to verify the content is numeric? http://www.google.com/search?q=shell+test+if+variable+numeric First link => http://www.unix.com/shell-programming-scripting/46276-check-variable-if-its-non-numeric.html Gosh, Google is full of answers these days.. Regards, Thomas