Commit c3ffc040 authored by Vitaly Lipatov's avatar Vitaly Lipatov

epm update: add --content-index for debug purposes

parent 722b6b37
......@@ -63,9 +63,12 @@ esac
case $PMTYPE in
apt-dpkg|aptitude-dpkg)
# move to update?
assure_exists apt-file
sudocmd apt-file update
if ! is_command apt-file ; then
assure_exists apt-file
sudocmd apt-file update
else
update_repo_if_needed
fi
docmd apt-file search $pkg_filenames
return ;;
packagekit)
......
......@@ -55,14 +55,23 @@ __save_available_packages()
epm_update()
{
local content_index
[ "$1" = "--content-index" ] && content_index=1 && shift
[ -z "$*" ] || fatal "No arguments are allowed here"
info "Running command for update remote package repository database"
info "Running update the package index files from remote package repository database ..."
local ret=0
warmup_hibase
case $BASEDISTRNAME in
"alt")
if [ -n "$content_index" ] ; then
load_helper epm-sh-altlinux-contents-index
update_alt_contents_index
return
fi
# TODO: hack against cd to cwd in apt-get on ALT
cd /
sudocmd apt-get update
......@@ -70,7 +79,6 @@ case $BASEDISTRNAME in
cd - >/dev/null
[ "$ret" = "0" ] || return
__check_for_epm_version
#sudocmd apt-get -f install || exit
__epm_touch_pkg
......@@ -94,9 +102,13 @@ case $PMTYPE in
[ "$ret" = "0" ] || return
;;
apt-dpkg)
if [ -n "$content_index" ] ; then
sudocmd apt-file update
return
fi
sudocmd apt-get update || return
#sudocmd apt-get -f install || exit
#sudocmd apt-get autoremove
# apt-get update retrieve Contents file too
#sudocmd apt-file update
;;
packagekit)
docmd pkcon refresh
......
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