Commit e1b0e984 authored by Vitaly Lipatov's avatar Vitaly Lipatov

epm: implement --put-to-repo=/path/repo support

parent 5fa5c5c1
...@@ -533,6 +533,9 @@ check_option() ...@@ -533,6 +533,9 @@ check_option()
--save-only) # HELPOPT: save the package/tarball after all convertations (instead of install it) --save-only) # HELPOPT: save the package/tarball after all convertations (instead of install it)
save_only="--save-only" save_only="--save-only"
;; ;;
--put-to-repo=*) # HELPOPT: put the package after all transformations to the repo (--put-to-repo=/path/to/repo)
put_to_repo="$(echo "$1" | sed -e 's|--put-to-repo=||')"
;;
--download-only) # HELPOPT: download only the package/tarball (before any convertation) --download-only) # HELPOPT: download only the package/tarball (before any convertation)
download_only="--download-only" download_only="--download-only"
;; ;;
......
...@@ -375,6 +375,12 @@ epm_install_files() ...@@ -375,6 +375,12 @@ epm_install_files()
return return
fi fi
if [ -n "$put_to_repo" ] ; then
load_helper epm-repopkg
epm_put_to_repo $files
return
fi
case $PMTYPE in case $PMTYPE in
packagekit) packagekit)
......
...@@ -40,6 +40,12 @@ epm_install_files_alt() ...@@ -40,6 +40,12 @@ epm_install_files_alt()
return return
fi fi
if [ -n "$put_to_repo" ] ; then
load_helper epm-repopkg
epm_put_to_repo $files
return
fi
__epm_check_if_src_rpm $files __epm_check_if_src_rpm $files
if [ -z "$repacked_pkgs" ] ; then if [ -z "$repacked_pkgs" ] ; then
......
...@@ -38,6 +38,13 @@ epm_install_files_apt_dpkg() ...@@ -38,6 +38,13 @@ epm_install_files_apt_dpkg()
return return
fi fi
if [ -n "$put_to_repo" ] ; then
load_helper epm-repopkg
epm_put_to_repo $files
return
fi
# TODO: if dpkg can't install due missed deps, trying with apt (as for now, --refuse-depends, --refuse-breaks don't help me) # TODO: if dpkg can't install due missed deps, trying with apt (as for now, --refuse-depends, --refuse-breaks don't help me)
if [ -n "$nodeps" ] ; then if [ -n "$nodeps" ] ; then
......
...@@ -33,6 +33,13 @@ epm_install_files_rpm() ...@@ -33,6 +33,13 @@ epm_install_files_rpm()
return return
fi fi
if [ -n "$put_to_repo" ] ; then
load_helper epm-repopkg
epm_put_to_repo $files
return
fi
__epm_check_if_src_rpm $files __epm_check_if_src_rpm $files
# --replacepkgs: Install the Package Even If Already Installed # --replacepkgs: Install the Package Even If Already Installed
......
...@@ -136,3 +136,8 @@ esac ...@@ -136,3 +136,8 @@ esac
} }
# call with packages to put to $put_to_repo
epm_put_to_repo()
{
epm_repo_pkgupdate "$put_to_repo" "$@"
}
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