function findRcFile(startDir, opts = {}) {
  const {recursive = false} = opts;
  let lastDir = '';
  let dir = startDir || process.cwd();
  if (!recursive) return findRcFileInDirectory(dir);

  while (lastDir.length !== dir.length) {
    const rcFile = findRcFileInDirectory(dir);
    if (rcFile) return rcFile;
    lastDir = dir;
    dir = path.join(dir, '..');
  }
}
@param {string} [startDir]
@param {{recursive?: boolean}} [opts]
@return {string|undefined}