From owner-freebsd-questions@FreeBSD.ORG Fri Feb 29 21:21:08 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 61F6E106566B for ; Fri, 29 Feb 2008 21:21:08 +0000 (UTC) (envelope-from fbsd.questions@rachie.is-a-geek.net) Received: from snoogles.rachie.is-a-geek.net (rachie.is-a-geek.net [66.230.99.27]) by mx1.freebsd.org (Postfix) with ESMTP id 2D8BE8FC12 for ; Fri, 29 Feb 2008 21:21:08 +0000 (UTC) (envelope-from fbsd.questions@rachie.is-a-geek.net) Received: from localhost (localhost [127.0.0.1]) by snoogles.rachie.is-a-geek.net (Postfix) with ESMTP id 1A30C1CCD5; Fri, 29 Feb 2008 12:21:06 -0900 (AKST) From: Mel To: freebsd-questions@freebsd.org Date: Fri, 29 Feb 2008 22:20:56 +0100 User-Agent: KMail/1.9.7 References: <4bded9640802150914x4c868f40ue0f21b8d8e163745@mail.gmail.com> <47C805B8.1040202@t-n-p.org> <4bded9640802291240r14c9b011t19f3734fb229853@mail.gmail.com> In-Reply-To: <4bded9640802291240r14c9b011t19f3734fb229853@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200802292220.56998.fbsd.questions@rachie.is-a-geek.net> Cc: Jeff Gold , jedrek Subject: Re: Scripting sysinstall 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: Fri, 29 Feb 2008 21:21:08 -0000 On Friday 29 February 2008 21:40:47 Jeff Gold wrote: > echo "8 partitions:" > /tmp/bsdlabel.conf > slice a 1 G 4.2BSD 2048 16384 32776 >> /tmp/bsdlabel.conf > slice b 2 G swap >> /tmp/bsdlabel.conf > echo "c: $size 0 unused 0 0" >> /tmp/bsdlabel.conf > slice d 10 p 4.2BSD 2048 16384 28552 >> /tmp/bsdlabel.conf > slice e 15 p 4.2BSD 2048 16384 8 >> /tmp/bsdlabel.conf > slice f 100 p 4.2BSD 2048 16384 28552 >> /tmp/bsdlabel.conf > bsdlabel -R ${disk}s1 /tmp/bsdlabel.conf Missing a few echo's there and better off for ease of editing in the future, to use the cat </tmp/bsdlabel.conf syntax. It will expand variables: $ cat t.sh #!/bin/sh FOO=bar cat </tmp/out foo is $FOO EOF $ sh t.sh && cat /tmp/out foo is bar > cat < $DESTDIR/etc/rc.conf > # FIXME: something should go in here. > EOF Yea, probably: ifconfig_${iface}="DHCP" keyrate="fast" sshd_enable="YES" Otherwise, nicely done :) -- Mel Problem with today's modular software: they start with the modules and never get to the software part.