Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions tasks/linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,9 @@ case "$available_manager" in

# yum install <pkg> and rpm -q <pkg> may produce different results because one package may provide another
# For example, 'vim' can be installed because the 'vim-enhanced' package provides 'vim'
# So, find out the exact package to get the status for
provided_package="$(rpm -q --whatprovides "$name")" || provided_package=
# So, find out the exact package to get the status for. Ensure the results are de-duplicated
# for packages which may match the whatprovides query more than once.
provided_package="$(rpm -q --whatprovides "$name" | sort -u)" || provided_package=

# <package>-<version> is the syntax for installing a specific version in yum
[[ $version ]] && full_name="${name}-${version}" || full_name="${name}"
Expand Down