title: Providing partial input to a bash command
body: <p>Say I'm running some command <code>foo</code>, which prompts the user for various things. I want to provide values for the first few prompts, but enter the rest manually (i.e. on <code>stdin</code>).</p>
  
  <p>How can I do this? I've tried</p>
  
  <pre><code>echo -e "foo\nbar\nbaz" | foo
  </code></pre>
  
  <p>This accepts all the inputs, but then gets an <code>EOF</code> from the input stream. I've also tried</p>
  
  <pre><code>foo &lt;(echo -e "foo\nbar\nbaz" &amp; cat /dev/stdin)
  </code></pre>
  
  <p>which didn't work either.</p>