title: Angular-Cli from NodeJS
body: <p>Building my project using Angular-Cli works when I use it directly from my terminal window like this:</p>
  
  <p><code>$ ng build</code></p>
  
  <p>Now I'd like to run it from <code>nodejs</code> using spawn. However,</p>
  
  <pre><code>const spawn = require('child_process').spawn;
  const bld = spawn("ng build");
  </code></pre>
  
  <p>throws:</p>
  
  <pre><code>child process has an error with code Error: spawn ng build ENOENT
  child process exited with code -2
  </code></pre>
  
  <p>Why is this happening? (I am running everything from inside the same folder.)</p>