mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Ref: #47689 - document additional kwarg passed to pip._check_if_installed function
This commit is contained in:
parent
0d19803106
commit
eac0178de2
1 changed files with 15 additions and 3 deletions
|
@ -187,9 +187,21 @@ def _check_pkg_version_format(pkg):
|
|||
def _check_if_installed(prefix, state_pkg_name, version_spec, ignore_installed,
|
||||
force_reinstall, upgrade, user, cwd, bin_env, env_vars,
|
||||
pip_list=False, **kwargs):
|
||||
# result: None means the command failed to run
|
||||
# result: True means the package is installed
|
||||
# result: False means the package is not installed
|
||||
'''
|
||||
Takes a package name and version specification (if any) and checks it is
|
||||
installed
|
||||
|
||||
Keyword arguments include:
|
||||
pip_list: optional dict of installed pip packages, and their versions,
|
||||
to search through to check if the package is installed. If not
|
||||
provided, one will be generated in this function by querying the
|
||||
system.
|
||||
|
||||
Returns:
|
||||
result: None means the command failed to run
|
||||
result: True means the package is installed
|
||||
result: False means the package is not installed
|
||||
'''
|
||||
ret = {'result': False, 'comment': None}
|
||||
|
||||
# If we are not passed a pip list, get one:
|
||||
|
|
Loading…
Add table
Reference in a new issue