title: Unhandled 'error' event when extracting zip file with nodejs
body: <p>I want to download a zip file and extract it with nodejs. This is what I have done so far:</p>
  
  <pre><code>var fs = require('fs');
  var wget = require('wget-improved');
  var filesizeHumanReadable = require('filesize');
  var unzip = require('unzip');
  
  var downloadCSS = function() {
    var src = 'http://7-zip.org/a/7za920.zip';
    var output = '/tmp/7z.zip';
    var options = {};
    var download = wget.download(src, output, options);
    download.on('error', function(err) {
        console.log(err);
    });
    download.on('start', function(fileSize) {
        console.log(filesizeHumanReadable(fileSize));
    });
    download.on('end', function(outputMessage) {
        console.log(outputMessage);
        console.log(output);
        fs.createReadStream(output).pipe(unzip.Extract({ path: '/tmp/' }));
    });
    download.on('progress', function(progress) {
        // code to show progress bar
    });
  }
  </code></pre>
  
  <p>The error message I get when running it:</p>
  
  <pre><code>mles-MacBook-Pro:test-api mles$ node index.js 
  375.83 KB
  Finished writing to disk
  /tmp/7z.zip
  events.js:85
        throw er; // Unhandled 'error' event
              ^
  Error: EPERM, unlink '/tmp'
      at Error (native)
  </code></pre>
  
  <p>Now I'm a bit baffled how to handle the error event and what my actual error is?</p>