Commit a846d446 authored by Vitaly Lipatov's avatar Vitaly Lipatov

real check if package(s) is installed

parent dead7eaa
...@@ -34,6 +34,7 @@ case $PMTYPE in ...@@ -34,6 +34,7 @@ case $PMTYPE in
esac esac
} }
# TODO: we have a problem with error status here
epm_packages() epm_packages()
{ {
local CMD local CMD
...@@ -46,8 +47,10 @@ case $PMTYPE in ...@@ -46,8 +47,10 @@ case $PMTYPE in
;; ;;
*-dpkg) *-dpkg)
#CMD="dpkg -l $pkg_filenames" #CMD="dpkg -l $pkg_filenames"
CMD="dpkg-query -W --showformat=\${Package}-\${Version}\n $pkg_filenames" CMD="dpkg-query -W --showformat=\${db:Status-Abbrev}\${Package}-\${Version}\n $pkg_filenames"
[ -n "$short" ] && CMD="dpkg-query -W --showformat=\${Package}\n $pkg_filenames" [ -n "$short" ] && CMD="dpkg-query -W --showformat=\${db:Status-Abbrev}\${Package}\n $pkg_filenames"
docmd $CMD | grep "^i" | sed -e "s|.* ||g"
return
;; ;;
snappy) snappy)
CMD="snappy info" CMD="snappy info"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment