title: How to write multiple line string using Bash with variables?
body: <p>How can I write multi-lines in a file called <code>myconfig.conf</code> using BASH?</p>
  
  <pre><code>#!/bin/bash
  kernel="2.6.39";
  distro="xyz";
  
  echo &lt;&lt;&lt; EOL
  line 1, ${kernel}
  line 2,
  line 3, ${distro}
  line 4
  line ...
  EOL &gt;&gt; /etc/myconfig.conf;
  cat /etc/myconfig.conf;
  </code></pre>