From owner-freebsd-questions@FreeBSD.ORG Sun Mar 29 12:57:32 2009 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 73DAF1065670 for ; Sun, 29 Mar 2009 12:57:32 +0000 (UTC) (envelope-from glen.j.barber@gmail.com) Received: from yw-out-2324.google.com (yw-out-2324.google.com [74.125.46.31]) by mx1.freebsd.org (Postfix) with ESMTP id 2A37D8FC20 for ; Sun, 29 Mar 2009 12:57:31 +0000 (UTC) (envelope-from glen.j.barber@gmail.com) Received: by yw-out-2324.google.com with SMTP id 5so1152899ywh.13 for ; Sun, 29 Mar 2009 05:57:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=MynQqq/2gB3OqbedDhHfh5l4d6pIig5bhLpgDrV4gzU=; b=uLPBjK3ngDuIr0B28DU0zaqVhzFPUTT9v4CdpHG5hUuJ6Ex6QGvHG1/dPYejggYNfm h92ibSp7CqaXrhlNQw/BlTbrIlrm5wXg0vQGtwGC1X7HLGWlYPejaIOiCzUebnUOdKMN xeb4yNwP+HV0KrF4kLEbshSjyDAFzXAjjPdEs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=Ay3Tpas70sUHtOp9wcjnEN42+8AWo5WTcN1ZKPTWSSOH+LRn2sW80F8TMAt9Cod11b 9KkRU34/zOuKBfw36hAdSFjGY5pjgG6G7p92aoBenwOqt25i/sGM0TJapU7iFBbp1s/R brnCQmPoIHyDCcZrZ18xtrJSqaVp3aejgj5LU= MIME-Version: 1.0 Received: by 10.100.121.12 with SMTP id t12mr1917080anc.71.1238331451441; Sun, 29 Mar 2009 05:57:31 -0700 (PDT) In-Reply-To: <20090329124524.GA48814@slackbox.xs4all.nl> References: <4ad871310903290437q269964d7k54a449f405fb31b2@mail.gmail.com> <20090329124524.GA48814@slackbox.xs4all.nl> Date: Sun, 29 Mar 2009 08:57:31 -0400 Message-ID: <4ad871310903290557v781c634fl6c8da854ea817ba8@mail.gmail.com> From: Glen Barber To: Roland Smith Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: "freebsd-questions@freebsd.org" Subject: Re: [OT] - Best Practices(TM) for Configuration File Changes 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: Sun, 29 Mar 2009 12:57:32 -0000 Hi, Roland. On Sun, Mar 29, 2009 at 8:45 AM, Roland Smith wrote: > > My configuration files are kept in git managed directories under > ~/setup/. =A0Every directory is its own > repository. The reason that I'm using git is because it does what I > need, is small and fast and doesn't require an external reporitory. For > configuration files which are usually plain text all revision control > systems would probably work OK. > > Every directory contains two perl scripts, check.pl and install.pl that > respectively check the differences between files in the repository and > in the filesystem and install files. Both these programs read a file > called 'filelist.'. This is a text file that has on every line > a file in the reposirory, a permission, and its location in the > filesystem (e.g. under /etc or /usr/local/etc for user root, or in $HOME > for other users) and any post-install commands. Both scripts only > process the filelists for the user that is running the script. > [snip] I currently use subversion for my University work (primarily because of how well it handles binary files). SVN seems to be a bit overkill for what I am looking for. > > The file from the first column is installed in the location in the third > column with the permissions listed in the second column. The rest of the > line (if any) is interpreted as a list of commands and executed by a subs= hell. > > This system makes it easy to see if there are any differences between > the configuration files in the repository and the real configuration > files (e.g. after a mergemaster run). And it can install every file in > its correct place. It also makes sure that users can only install their > own files, by reading only that user's filelist. > I'll have to play around with this -- interesting. Thanks! --=20 Glen Barber