code: function processFile(rootPath, log) {
    return (file, callback) => {
      const filePath = path.join(rootPath, file.path);
      const writeMode = isStream(file.data) ? WriteMode.STREAM : WriteMode.UTF8;
      write(filePath, file.data, writeMode, (error) => {
        if (log === true && !error) {
          console.log(`Successfully wrote file '${file.path}'`);
        }
  
        async.nextTick(callback, error, file);
      });
    };
  }
docs: Process a single file.