title: How to include pipe character in an argument to a batch file from a bash script?
body: <p>I have a shell script that I want to execute this line:</p>
  
  <pre><code>qtvars.bat vsstart "qt.sln" /BUILD "Debug|Win32"
  </code></pre>
  
  <p><s>This works fine (though I had to modify <code>qtvars.bat</code>, but that's beside the point). The problem is that I want the command to execute to be in a variable:</s>
  EDIT: This doesn't work either, if I type it into bash. Previously I was typing it into <code>cmd.exe</code>, which hardly made for a fair comparison.</p>
  
  <pre><code>command="qtvars.bat"
  args="vsstart"
  
  $command $args "qt.sln" /BUILD "Debug|Win32"
  </code></pre>
  
  <p>Now it chokes on the pipe! I get this message:</p>
  
  <pre><code>'Win32' is not recognized as an internal or external command,
  operable program or batch file.
  </code></pre>
  
  <p>I've tried a bunch of forms of escaping the quotes and/or pipe, all to no avail. Interestingly, it works when it's an executable rather than a batch file, e.g.:</p>
  
  <pre><code>command="devenv.exe"
  args=""
  
  $command $args "qt.sln" /BUILD "Debug|Win32"
  </code></pre>
  
  <p>Thanks for any ideas.</p>