docs: function updatePaths(pathMap, options, log) {
      if (!pathMap || typeof pathMap !== "object" || Array.isArray(pathMap)) {
          throw new Error("An object mapping from target paths to source paths is required.");
      }
  
      log = log || function(message) { };
  
      var updated = false;
  
      // Iterate in sorted order to ensure directories are created before files under them.
      Object.keys(pathMap).sort().forEach(function (targetPath) {
          var sourcePath = pathMap[targetPath];
          updated = updatePathInternal(sourcePath, targetPath, options, log) || updated;
      });
  
      return updated;
  }