[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: editfiles question
From: |
Jamie Wilkinson |
Subject: |
Re: editfiles question |
Date: |
Wed, 1 Sep 2004 00:05:47 +1000 |
User-agent: |
Mutt/1.5.6+20040803i |
This one time, at band camp, Sven Mueller wrote:
>Hi.
>
>From the documentation, I am not certain how to achieve the following
>task.
>Let's say I want to edit /etc/passwd (actually I am editing a similarly
>formated, but different file), and I want the following to be achieved:
>
>- I want the file to be created if it doesn't exist (AutoCreate takes
> care of this)
>- I want a line "root:..1234567890123:0:0::/bin/bash" be added to the
> file if it doesn't exist, overwriting any root:.* lines that might
> exist.
http://shipyard.com.au/shipyard/articles/sysadmin/cfengine-configfiles.py
--
jaq@spacepants.org http://spacepants.org/jaq.gpg