Commit d0b9056d authored by Vitaly Lipatov's avatar Vitaly Lipatov

add conary package manager support

parent 865a65ac
......@@ -47,7 +47,10 @@ case $PMTYPE in
# sudocmd urpme --auto-orphans
# ;;
zypper-rpm)
sudocmd zypper verify || exit
sudocmd zypper verify
;;
conary)
sudocmd conary verify
;;
*)
fatal "Have no suitable command for $PMTYPE"
......
......@@ -62,6 +62,9 @@ __epm_filelist_name()
zypper-rpm)
CMD="rpm -ql"
;;
conary)
CMD="conary query --ls"
;;
pacman)
docmd pacman -Ql $pkg_names | sed -e "s|.* ||g"
return
......
......@@ -67,6 +67,10 @@ case $PMTYPE in
# FIXME: --version=
docmd npackdcl info --package=$pkg_names
;;
conary)
is_installed $pkg_names && docmd conary query $pkg_names --info && return
docmd conary repquery $pkg_names --info
;;
slackpkg)
docmd /usr/sbin/slackpkg info $pkg_names
;;
......
......@@ -123,6 +123,9 @@ epm_install_names()
mpkg)
sudocmd mpkg install $@
return ;;
conary)
sudocmd conary update $@
return ;;
npackd)
# FIXME: correct arg
__separate_sudocmd_foreach "npackdcl add --package=" "npackdcl update --package=" $@
......
......@@ -70,6 +70,9 @@ case $PMTYPE in
CMD="npackdcl list --status=installed"
# TODO: use search if pkg_filenames is not empty
;;
conary)
CMD="conary query"
;;
# chocolatey)
# CMD="chocolatey list"
# ;;
......
......@@ -123,7 +123,11 @@ __epm_query_name()
[ -n "$short" ] && CMD="dpkg-query -W --showformat=\${Package}\n"
;;
npackd)
CMD="npackdcl path --package=$@"
docmd "npackdcl path --package=$@"
return
;;
conary)
CMD="conary query"
;;
brew)
warning "fix query"
......
......@@ -84,6 +84,9 @@ __do_query()
pacman)
CMD="pacman -Qo"
;;
conary)
CMD="conary query --path"
;;
slackpkg)
# note: need remove leading slash for grep
docmd grep -R -- "$(echo $@ | sed -e 's|^/\+||g')" /var/log/packages | sed -e "s|/var/log/packages/||g"
......
......@@ -60,6 +60,9 @@ epm_release_upgrade()
pacman)
epm Upgrade
;;
conary)
epm Upgrade
;;
*)
fatal "Have no suitable command for $PMTYPE"
;;
......
......@@ -82,6 +82,9 @@ epm_remove_names()
mpkg)
sudocmd mpkg remove $@
return ;;
conary)
sudocmd conary erase $@
return ;;
npackd)
sudocmd npackdcl remove --package=$@
return ;;
......
......@@ -52,6 +52,9 @@ case $PMTYPE in
mpkg)
CMD="mpkg search"
;;
conary)
CMD="conary repquery"
;;
npackd)
docmd npackdcl search --query="$string" --status=all
return
......
......@@ -279,6 +279,9 @@ case $DISTRNAME in
SUSE|SLED|SLES)
CMD="zypper-rpm"
;;
ForesightLinux|rPathLinux)
CMD="conary"
;;
Windows)
CMD="chocolatey"
;;
......
......@@ -51,6 +51,9 @@ epm_upgrade()
emerge)
CMD="emerge -NuDa world"
;;
conary)
CMD="conary updateall"
;;
pkgsrc)
CMD="freebsd-update fetch install"
;;
......
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