Ejemplo n.º 1
0
def nopackage(pkg_name, options=None):
    """
    Require a rpm package to be uninstalled.

    Example::

        from fabtools import require

        require.rpm.nopackage('emacs')
    """
    if is_installed(pkg_name):
        uninstall(pkg_name, options)
Ejemplo n.º 2
0
def nopackage(pkg_name, options=None):
    """
    Require an RPM package to be uninstalled.

    Example::

        from fabtools import require

        require.rpm.nopackage('emacs')
    """
    if is_installed(pkg_name):
        uninstall(pkg_name, options)
Ejemplo n.º 3
0
def nopackages(pkg_list, options=None):
    """
    Require several rpm packages to be uninstalled.

    Example::

        from fabtools import require

        require.rpm.nopackages([
            'unzip',
            'vim',
            'emacs',
        ])
    """
    pkg_list = [pkg for pkg in pkg_list if is_installed(pkg)]
    if pkg_list:
        uninstall(pkg_list, options)
Ejemplo n.º 4
0
def nopackages(pkg_list, options=None):
    """
    Require several RPM packages to be uninstalled.

    Example::

        from fabtools import require

        require.rpm.nopackages([
            'unzip',
            'vim',
            'emacs',
        ])
    """
    pkg_list = [pkg for pkg in pkg_list if is_installed(pkg)]
    if pkg_list:
        uninstall(pkg_list, options)