From owner-freebsd-questions@FreeBSD.ORG Sun Feb 22 08:01:30 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C617216A54E for ; Sun, 22 Feb 2004 08:01:30 -0800 (PST) Received: from sccmmhc02.asp.att.net (sccmmhc02.asp.att.net [204.127.203.184]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8BF7143D2D for ; Sun, 22 Feb 2004 08:01:30 -0800 (PST) (envelope-from david.fleck@mchsi.com) Received: from grond (12-216-14-105.client.mchsi.com[12.216.14.105]) by sccmmhc02.asp.att.net (sccmmhc02) with SMTP id <20040222160129mm200s5634e>; Sun, 22 Feb 2004 16:01:30 +0000 Date: Sun, 22 Feb 2004 10:01:29 -0600 (CST) From: David Fleck Sender: dcf@grond.sourballs.org To: Julien Gabel In-Reply-To: <49326.192.168.0.97.1077463973.squirrel@webmail.thilelli.net> Message-ID: <20040222095116.X58331@grond.sourballs.org> References: <6.0.0.22.0.20040222091410.03a06988@pop.face2interface.com><4038C625.1000102@countrypure.net> <6.0.0.22.0.20040222102019.05afa958@pop.face2interface.com> <49326.192.168.0.97.1077463973.squirrel@webmail.thilelli.net> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: Marty Landman cc: freebsd-questions@freebsd.org Subject: Re: seeking shell scripting resources X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 22 Feb 2004 16:01:31 -0000 On Sun, 22 Feb 2004, Julien Gabel wrote: > Haven't found much around at all on shell programming and would like > to start learning it. Any more resources would be most welcome to find > out about. Shells differ in their programming constructs, so anything you learn in one shell may not be transferrable to others. As a personal preference, I usually try to write scripts for /bin/sh (for portability), unless I need a ksh or bash construct. bash is a variant of sh, with a lot of bells and whistles added, so techniques that work in bash *usually* work in sh (and ksh). With that preface, you might try http://www.tldp.org/LDP/abs/html/ as a start. It's bash-oriented, but a lot if it will apply to other shells (sh and ksh, not so much csh and tcsh) as well. And your system scripts are also an excellent place to learn by example. -- David Fleck david.fleck@mchsi.com