docs: function flattenPath(file, opts) {
    var fileName = path.basename(file.path);
    var dirs;
  
    if (!opts.includeParents && !opts.subPath) {
      return fileName;
    }
  
    dirs = path.dirname(file.relative).split(path.sep);
    if (opts.includeParents) {
      dirs = includeParents(dirs, opts.includeParents);
    }
    if (opts.subPath) {
      dirs = subPath(dirs, opts.subPath);
    }
  
    dirs.push(fileName);
    return path.join.apply(path, dirs);
  }