def package(pkg_name, repos=None, yes=None, options=None): """ Require a rpm package to be installed. Example:: from fabtools import require require.rpm.package('emacs') """ if not is_installed(pkg_name): install(pkg_name, repos, yes, options)
def package(pkg_name, repos=None, yes=None, options=None): """ Require an RPM package to be installed. Example:: from fabtools import require require.rpm.package('emacs') """ if not is_installed(pkg_name): install(pkg_name, repos, yes, options)
def packages(pkg_list, repos=None, yes=None, options=None): """ Require several rpm packages to be installed. Example:: from fabtools import require require.rpm.packages([ 'nano', 'unzip', 'vim', ]) """ pkg_list = [pkg for pkg in pkg_list if not is_installed(pkg)] if pkg_list: install(pkg_list, repos, yes, options)
def packages(pkg_list, repos=None, yes=None, options=None): """ Require several RPM packages to be installed. Example:: from fabtools import require require.rpm.packages([ 'nano', 'unzip', 'vim', ]) """ pkg_list = [pkg for pkg in pkg_list if not is_installed(pkg)] if pkg_list: install(pkg_list, repos, yes, options)