lib/pip.js
function requirementsFileExists(servicePath, options, fileName) {
  if (
    options.usePoetry &&
    fse.existsSync(path.join(servicePath, 'pyproject.toml'))
  ) {
    return true;
  }

  if (options.usePipenv && fse.existsSync(path.join(servicePath, 'Pipfile'))) {
    return true;
  }

  if (fse.existsSync(fileName)) {
    return true;
  }

  return false;
}
function requirementsFileExists(servicePath, options, fileName) {
  if (
    options.usePoetry &&
    fse.existsSync(path.join(servicePath, 'pyproject.toml'))
  ) {
    return true;
  }

  if (options.usePipenv && fse.existsSync(path.join(servicePath, 'Pipfile'))) {
    return true;
  }

  if (fse.existsSync(fileName)) {
    return true;
  }

  return false;
}
function requirementsFileExists ( servicePath , options , fileName ) { if ( options . usePoetry && fse . existsSync ( path . join ( servicePath , 'pyproject.toml' ) ) ) { return true ; } if ( options . usePipenv && fse . existsSync ( path . join ( servicePath , 'Pipfile' ) ) ) { return true ; } if ( fse . existsSync ( fileName ) ) { return true ; } return false ; }
This checks if requirements file exists.
@param {string} servicePath
@param {Object} options
@param {string} fileName
This checks if requirements file exists .