def __init__(self, package, version="", flag="", repo=""): """ Constructs a new ``RscriptRequirement``, using the ``PackageRequirement`` constructor. >>> pr = RscriptRequirement( ... 'formatR', version='1.4', flag='-e', ... repo="http://cran.rstudio.com") >>> pr.manager 'R' >>> pr.package 'formatR' >>> pr.version '1.4' >>> pr.flag '-e' >>> pr.repo 'http://cran.rstudio.com' :param package: A string with the name of the package to be installed. :param version: A version string. Leave empty to specify latest version. :param flag: A string that specifies any additional flags, that are passed to the manager. :param repo: The repository from which the package to be installed is from. """ PackageRequirement.__init__(self, 'R', package, version) self.flag = flag self.repo = repo
def __init__(self, package, version="", flag="", repo=""): """ Constructs a new ``RscriptRequirement``, using the ``PackageRequirement`` constructor. >>> pr = RscriptRequirement( ... 'formatR', version='1.4', flag='-e', ... repo="http://cran.rstudio.com") >>> pr.type 'R' >>> pr.package 'formatR' >>> pr.version '1.4' >>> pr.flag '-e' >>> pr.repo 'http://cran.rstudio.com' :param package: A string with the name of the package to be installed. :param version: A version string. Leave empty to specify latest version. :param flag: A string that specifies any additional flags, that are passed to the type. :param repo: The repository from which the package to be installed is from. """ PackageRequirement.__init__(self, 'R', package, version) self.flag = flag self.repo = repo
def __init__(self, package, version=""): """ Constructs a new ``CondaRequirement``, using the ``PackageRequirement`` constructor. >>> pr = CondaRequirement('clang') >>> pr.manager 'conda' >>> pr.package 'clang' :param package: A string with the name of the package to be installed. :param version: A version string. Leave empty to specify latest version. """ PackageRequirement.__init__(self, 'conda', package, version)
def __init__(self, package, version=""): """ Constructs a new ``PythonRequirement``, using the ``PackageRequirement`` constructor. >>> pr = PythonRequirement('setuptools', '19.2') >>> pr.manager 'pip' >>> pr.package 'setuptools' >>> pr.version '19.2' :param package: A string with the name of the package to be installed. :param version: A version string. Leave empty to specify latest version. """ PackageRequirement.__init__(self, 'pip', package, version)
def __init__(self, package, version=""): """ Constructs a new ``NpmRequirement``, using the ``PackageRequirement`` constructor. >>> pr = NpmRequirement('ramllint', '6.2') >>> pr.manager 'npm' >>> pr.package 'ramllint' >>> pr.version '6.2' :param package: A string with the name of the package to be installed. :param version: A version string. Leave empty to specify latest version. """ PackageRequirement.__init__(self, 'npm', package, version)
def __init__(self, package, version=""): """ Constructs a new ``PipRequirement``, using the ``PackageRequirement`` constructor. >>> pr = PipRequirement('setuptools', '19.2') >>> pr.manager 'pip' >>> pr.package 'setuptools' >>> pr.version '19.2' :param package: A string with the name of the package to be installed. :param version: A version string. Leave empty to specify latest version. """ PackageRequirement.__init__(self, 'pip', package, version)
def __init__(self, package, version=""): """ Constructs a new ``JuliaRequirement``, using the ``PackageRequirement`` constructor. >>> pr = JuliaRequirement('Lint', '19.2') >>> pr.type 'julia' >>> pr.package 'Lint' >>> pr.version '19.2' :param package: A string with the name of the package to be installed. :param version: A version string. Leave empty to specify latest version. """ PackageRequirement.__init__(self, 'julia', package, version)
def __init__(self, package, version="", require=""): """ Constructs a new ``GemRequirement``, using the ``PackageRequirement`` constructor. >>> pr = GemRequirement('setuptools', '19.2', 'flag') >>> pr.manager 'gem' >>> pr.package 'setuptools' >>> pr.version '19.2' >>> pr.require 'flag' :param package: A string with the name of the package to be installed. :param version: A version string. Leave empty to specify latest version. :param require: A string that specifies any additional flags, that would be used with ``require``. """ PackageRequirement.__init__(self, 'gem', package, version) self.require = require
def __init__(self, package, version="", flag=""): """ Constructs a new ``JuliaRequirement``, using the ``PackageRequirement`` constructor. >>> pr = JuliaRequirement('"Pkg.add(\"Lint\")"', '19.2', '-e') >>> pr.manager 'julia' >>> pr.package '"Pkg.add(\"Lint\")"' >>> pr.version '19.2' >>> pr.flag '-e' :param package: A string with the name of the package to be installed. :param version: A version string. Leave empty to specify latest version. :param flag: A string that specifies any additional flags, that are passed to the manager. """ PackageRequirement.__init__(self, 'julia', package, version) self.flag = flag
def __init__(self, package, version="", flag=""): """ Constructs a new ``GoRequirement``, using the ``PackageRequirement`` constructor. >>> pr = GoRequirement('github.com/golang/lint/golint', '19.2', '-u') >>> pr.manager 'go' >>> pr.package 'github.com/golang/lint/golint' >>> pr.version '19.2' >>> pr.flag '-u' :param package: A string with the name of the package to be installed. :param version: A version string. Leave empty to specify latest version. :param flag: A string that specifies any additional flags, that are passed to the manager. """ PackageRequirement.__init__(self, 'go', package, version) self.flag = flag