title: In shell script, how can I properly escape double quotes so I can run a command with quoted params?
body: <p>I want to run something like this in my shell script:</p>
  
  <pre><code>./node_modules/.bin/npm-run-all -p "ng lint myapp"
  </code></pre>
  
  <p>I have a for loop to generate the quoted string:</p>
  
  <pre><code>LINT=""
  for app in $APPS
  do
      LINT="$LINT \"ng lint ${app}\""
  done
  </code></pre>
  
  <p>I thought using \" will be able to generate the string I want.  But when I run:</p>
  
  <pre><code>./node_modules/.bin/npm-run-all -p ${LINT}
  </code></pre>
  
  <p>I get:</p>
  
  <pre><code>ERROR: Task not found: ""ng", myapp""
  </code></pre>
  
  <p>Seems like this is being run:</p>
  
  <pre><code>./node_modules/.bin/npm-run-all -p \"ng lint myapp\"
  </code></pre>
  
  <p>What is the proper way to escape the double quote so that I will be running this instead?:</p>
  
  <pre><code>./node_modules/.bin/npm-run-all -p "ng lint myapp"
  </code></pre>