From: Brian Candler Date: 2007-02-09T05:22:08+09:00 Subject: Re: Ruby as a configuration language On Fri, Feb 09, 2007 at 01:00:09AM +0900, Tapio Kelloniemi wrote: > # An example package description file. The actual building commands are > # written in a bash script. > name = "gcc" > version = "4.1.1" > title = " "GNU Compiler Collection" > description = "..." > > archive { > localname = "#{name}-#{version}.tar.bz2" > originalname = "#{name}-#{version}.tar.gz" > baseurl "ftp://ftp.gnu.org/gnu/gcc/#{version}/" > baseurl "ftp.mirror.site/gnu/gcc/#{version}/" > convert = "gz-bz2" > } > > # Optional components > feature "gfortran" { > title = "Fortran compiler" > depend "gmp" > } > > ### END example I did something a bit like this, using Rake, for building mail software. You can download the source, which is basically just a bunch of package building scripts, from http://linnet.rubyforge.org/ (take the linnet-src package, or check out from cvs) You might be able to steal some ideas. It's not as abstracted as the way you've described above, but I found in practice that the software packages I was building didn't all fit into identical moulds.