title: Variables within the printf
body: <p>Using bash I need to print some txt file which actually is another python script consisted of some tittles moved into the variable (t) within the main script</p>
  
  <pre><code>t="test"
  
  printf "import pymol
  cmd.load("${t}.pdb")" &gt; ./script.py
  </code></pre>
  
  <p>the problem that the resulting script.py looks exactly like what I've defined in my main script</p>
  
  <pre><code>import pymol
  cmd.load("${t}.pdb")"
  </code></pre>
  
  <p>so how I can to past correctly value of 't' within the resulted script.py?</p>
  
  <pre><code>import pymol
  cmd.load("test.pdb")"
  </code></pre>