lib/specinfra/command/arch/base/package.rb in specinfra-2.50.1 vs lib/specinfra/command/arch/base/package.rb in specinfra-2.50.2

- old
+ new

@@ -3,10 +3,10 @@ def check_is_installed(package,version=nil) if version grep = version.include?('-') ? "^#{escape(version)}$" : "^#{escape(version)}-" "pacman -Q #{escape(package)} | awk '{print $2}' | grep '#{grep}'" else - "pacman -Q #{escape(package)}" + "pacman -Q #{escape(package)} || pacman -Qg #{escape(package)}" end end def get_version(package, opts=nil) "pacman -Qi #{package} | grep Version | awk '{print $3}'"