title: It simpler to modify the Linux configuration file (perl)?
body: <p>There is a linux configuration file of this type:</p>
  
  <pre><code>[header1]
  key1=var1
  
  [header2]
  key2=var2
  </code></pre>
  
  <p>How do I change a variable from var1 to var1new and immediately write Changes (in the absence of key1 create it)?</p>