docs: function _write(dest, source, callback) {
    var itemPath = path.join(dest, source.name);
    // switch according to type of the current root item
    switch(source.type) {
      case TYPE_FILE:
        if (source.data instanceof stream.Readable) {
          // stream data => pipe it to destination stream
          source.data.pipe(fs.createWriteStream(itemPath));
          source.data.on('end', callback);
          return;
        }
        // write data to the file as a string or a buffer
        return fs.writeFile(
          itemPath,
          (typeof source.data === 'undefined' || source.data === null) ? '' : source.data,
          callback
        );
      case TYPE_FOLDER:
        return fs.mkdir(itemPath, _folderWritten.bind(null, itemPath, source, callback));
      case TYPE_ALIAS:
        return fs.symlink(source.orig, itemPath, callback);
      default:
        // ignore unknown type
        return callback();
    }
  }