> Christopher Browne wrote:
>> I'd *love* to have something that would say something like...
>>   AssignField LHS="com.foo.bar.jdbc.url"
>>               RHS="pgsql:$(dbhost):$(dbport):$(dbuser)"
>>               separator="="
>
> Did someone consider code along the lines of
> SplitOn = ( = )
> SetLine "com.foo.bar.jdbc.url=pgsql:somehost:5432:user"
> ReplaceLinesMatchingField "1"
> ?

That would do it too, although I think the syntax needs to involve
using one command, with multiple parameters, not three with one.

Maybe...

 SetLine Value = "com.foo.bar.jdbc.url=pgsql:somehost:5432:user"
         Separator = ( = )
         MatchField = ( 1 )

The point is to have a reasonably elegant syntax for this, as that is,
after all, the point of cfengine.
-- 
(reverse (concatenate 'string "moc.liamg" "@" "enworbbc"))
http://cbbrowne.com/info/
If we were meant to fly, we wouldn't keep losing our luggage.
_______________________________________________
Help-cfengine mailing list
Help-cfengine@gnu.org
http://lists.gnu.org/mailman/listinfo/help-cfengine

Reply via email to