Commit 216e67c1 authored by Vitaly Lipatov's avatar Vitaly Lipatov

backported to p8 as 1.6.8-alt0.M80P.1 (with rpmbph script)

parents 6e8ec878 435acebb
...@@ -19,22 +19,23 @@ ...@@ -19,22 +19,23 @@
load_helper epm-query load_helper epm-query
__replace_text_in_alt_repo()
{
local i
for i in /etc/apt/sources.list /etc/apt/sources.list.d/*.list ; do
[ -s "$i" ] || continue
regexp_subst "$1" "$i"
done
}
__replace_alt_version_in_repo() __replace_alt_version_in_repo()
{ {
local i local i
assure_exists apt-repo assure_exists apt-repo
echo "Upgrading $DISTRNAME from $1 to $2 ..." echo "Upgrading $DISTRNAME from $1 to $2 ..."
docmd apt-repo list | sed -e "s|\($1/branch\)|{\1}->$2/branch<|g" | egrep --color -- "$1/branch" docmd apt-repo list | sed -e "s|\($1/branch\)|{\1}->{$2/branch}|g" | egrep --color -- "$1/branch"
confirm "Are these correct changes?" || fatal "Exiting" confirm "Are these correct changes?" || fatal "Exiting"
for i in /etc/apt/sources.list /etc/apt/sources.list.d/*.list ; do __replace_text_in_alt_repo "/^ *#/! s!$1/branch!$2/branch!g"
[ -s "$i" ] || continue
# TODO: only for uncommended strings
#sed -i -r -e "s!$1/branch!$2/branch!g" $i
regexp_subst "/^ *#/! s!$1/branch!$2/branch!g" $i
# TODO: start with improve to [p8] - install some package firstly?
regexp_subst "/^ *#/! s!\[$1\]![\$2]!g" $i
done
docmd apt-repo list docmd apt-repo list
} }
...@@ -43,27 +44,37 @@ __update_alt_repo_to_next_distro() ...@@ -43,27 +44,37 @@ __update_alt_repo_to_next_distro()
case "$DISTRVERSION" in case "$DISTRVERSION" in
p6) p6)
docmd epm install apt-conf-branch || fatal docmd epm install apt-conf-branch || fatal
load_helper epm-repofix
pkg_filenames= epm_repofix
__replace_alt_version_in_repo p6 p7 __replace_alt_version_in_repo p6 p7
docmd epm update __replace_text_in_alt_repo "/^ *#/! s!\[p6\]![updates]!g"
docmd epm install apt rpm || fatal docmd epm update || fatal
docmd epm install apt rpm apt-conf-branch || fatal
__replace_text_in_alt_repo "/^ *#/! s!\[updates\]![p7]!g"
docmd epm update || fatal
docmd epm upgrade docmd epm upgrade
docmd epm update-kernel docmd epm update-kernel
info "Run epm release-upgrade again for update to p8" info "Run epm release-upgrade again for update to p8"
;; ;;
p7) p7)
docmd epm install apt-conf-branch || fatal docmd epm install apt-conf-branch || fatal
load_helper epm-repofix
pkg_filenames= epm_repofix
__replace_alt_version_in_repo p7 p8 __replace_alt_version_in_repo p7 p8
docmd epm update __replace_text_in_alt_repo "/^ *#/! s!\[p7\]![updates]!g"
docmd epm install apt rpm || fatal docmd epm update || fatal
docmd epm install apt rpm apt-conf-branch || fatal
__replace_text_in_alt_repo "/^ *#/! s!\[updates\]![p7]!g"
docmd epm update || fatal
if is_installed systemd ; then if is_installed systemd ; then
docmd epm install systemd || fatal docmd epm install systemd || fatal
fi fi
docmd epm upgrade || fatal docmd epm upgrade || fatal
#info " # epmi branding-simply-linux-release branding-simply-linux-graphics" #info " # epmi branding-simply-linux-release branding-simply-linux-graphics"
docmd epm update-kernel docmd epm update-kernel || fatal
;; ;;
*) *)
info "Have no idea how to update from $DISTRNAME $DISTRVERSION" info "Have no idea how to update from $DISTRNAME $DISTRVERSION. Try install branding-simply-linux-release package before."
return 1 return 1
esac esac
} }
...@@ -78,8 +89,6 @@ epm_release_upgrade() ...@@ -78,8 +89,6 @@ epm_release_upgrade()
ALTLinux) ALTLinux)
docmd epm update docmd epm update
docmd epm install apt rpm docmd epm install apt rpm
load_helper epm-repofix
pkg_filenames= epm_repofix
__update_alt_repo_to_next_distro __update_alt_repo_to_next_distro
return return
;; ;;
......
# This spec is backported to ALTLinux p8 automatically by rpmbph script from etersoft-build-utils. # This spec is backported to ALTLinux p8 automatically by rpmbph script from etersoft-build-utils.
# #
Name: eepm Name: eepm
Version: 1.6.7 Version: 1.6.8
Release: alt0.M80P.1 Release: alt0.M80P.1
Summary: Etersoft EPM package manager Summary: Etersoft EPM package manager
...@@ -67,9 +67,13 @@ chmod a+x %buildroot%_datadir/%name/{serv-,epm-}* ...@@ -67,9 +67,13 @@ chmod a+x %buildroot%_datadir/%name/{serv-,epm-}*
%_sysconfdir/bash_completion.d/cerv %_sysconfdir/bash_completion.d/cerv
%changelog %changelog
* Fri Apr 15 2016 Vitaly Lipatov <lav@altlinux.ru> 1.6.7-alt0.M80P.1 * Mon Apr 18 2016 Vitaly Lipatov <lav@altlinux.ru> 1.6.8-alt0.M80P.1
- backport to ALTLinux p8 (by rpmbph script) - backport to ALTLinux p8 (by rpmbph script)
* Mon Apr 18 2016 Vitaly Lipatov <lav@altlinux.ru> 1.6.8-alt1
- small output fix
- rewrite release-upgrade
* Fri Apr 15 2016 Vitaly Lipatov <lav@altlinux.ru> 1.6.7-alt1 * Fri Apr 15 2016 Vitaly Lipatov <lav@altlinux.ru> 1.6.7-alt1
- release_upgrade: fix sign replacement - release_upgrade: fix sign replacement
- fix epm_update - fix epm_update
......
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