/**
 * File:	etc_hosts.scr
 * Summary:	Agent for reading/writing /etc/hosts
 * Access:	read/write
 * Authors:	Michal Svec <msvec@suse.cz>
 * See:		hosts(5)
 *
 * Example:
 *   Dir(.etc.hosts)
 *   (["127.0.0.1", "::1"])
 **
 *   Read(.etc.hosts."127.0.0.1")
 *   ("localhost")
 **
 *   Write(.etc.hosts."10.20.1.29", "beholder.suse.cz beholder")
 *   (true)
 *
 * $Id: etc_hosts.scr 12980 2003-12-06 20:51:23Z msvec $
 */
.etc.hosts

`ag_ini(
    `IniAgent( "/etc/hosts",
	$[
	    "options"	: [ "global_values", "flat" ],
	    "comments"	: [ "^#.*", "^[ \t]*$" ],
	    "params"	: [
		$[ "match" : [ "^[ \t]*([^ \t]+)[ \t]+(.+)[ \t]*$", "%-15s %s" ] ]
	    ]
	]
))
