Subject: Searching for macro processor of some kind
To: None <netbsd-users@NetBSD.org>
From: Matthias Scheler <tron@zhadum.org.uk>
List: netbsd-users
Date: 12/09/2006 22:01:36
Hello,
I'm searching for a macro processor that I want to use to generate a
configuration file a network appliance. It should be able to turn an
input file like this ...
FOO="a b c"
BAR="1 2 3"
BLA="fasel"
command0
command1 @FOO@ using a spoon
command2 @BAR@ with @BLA@
command3
... into an output file like this:
command0
command1 a using a spoon
command1 b using a spoon
command1 c using a spoon
command2 1 with fasel
command2 2 with fasel
command2 3 with fasel
command3
I could hack together a Perl or shell script which does this. But I guess
such a tool already exist. Any recommendations?
Kind regards
--
Matthias Scheler http://zhadum.org.uk/