Sophie

Sophie

distrib > Mageia > 4 > x86_64 > by-pkgid > a918147e816a04e85f8654f72077e879 > files > 68

perl-Libconf-0.42.10-6.mga4.x86_64.rpm

<?xml version="1.0" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<link rev="made" href="mailto:root@localhost" />
</head>

<body style="background-color: white">



<ul id="index">
  <li><a href="#NAME">NAME</a></li>
  <li><a href="#DESCRIPTION">DESCRIPTION</a></li>
  <li><a href="#CONSTRUCTOR">CONSTRUCTOR</a></li>
</ul>

<h1 id="NAME">NAME</h1>

<p>Libconf::Glueconf::Generic::Shell - Glueconf high level template for shell styles config files</p>

<h1 id="DESCRIPTION">DESCRIPTION</h1>

<pre><code>  use Data::Dumper;
  my $make_conf = new Libconf::Glueconf::Generic::Shell({ filename =&gt; &quot;/etc/make.conf&quot;
                                                          shell_style =&gt; &quot;true_bash&quot;,
                                                          shell_command =&gt; &quot;/bin/bash&quot;,
                                                        });
  print Dumper($make_conf) . &quot;\n&quot;;
  $make_conf-&gt;{CHOST} = &#39;i586-pc-linux-gnu&#39;;
  $make_conf-&gt;write_conf(&#39;/etc/make.conf_new&#39;);</code></pre>

<p>This template maps any shell config files into a virtual hashref with key =&gt; value association. You can edit the hash and regenerate the config file.</p>

<h1 id="CONSTRUCTOR">CONSTRUCTOR</h1>

<pre><code>  my $conf = new Libconf::Glueconf::Generic::Shell({ filename =&gt; &quot;shell_style.conf&quot;,
                                                     simplify_quote =&gt; 1,
                                                   });</code></pre>

<p>The constructore returns a variable which is at the same time an object on which you can call the <b>Glueconf General methods</b> (see <a>Libconf::Glueconf</a> ), and at the same time a reference on a hash, whith the keys/values of your config file.</p>

<p>the options you can give to the constructore are the same as in <a>Libconf::Templates::Shell</a></p>


</body>

</html>