Commit 2b53de67 authored by Vitaly Lipatov's avatar Vitaly Lipatov

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

parents 3606448b d3d20073
......@@ -32,9 +32,10 @@ case $PMTYPE in
apt-rpm)
# ALT Linux only
assure_exists /etc/buildreqs/files/ignore.d/apt-scripts apt-scripts
__epm_orphan_altrpm
info "TODO: this was just a list of orphans"
# | sudocmd epm remove
echo "We will try remove all installed packages which are missed in repositories"
warning "Use with caution!"
local PKGLIST=$(__epm_orphan_altrpm | sed -e "s/\.32bit//g" | grep -v -- "^kernel")
docmd epm remove $PKGLIST
;;
apt-dpkg|aptitude-dpkg)
assure_exists deborphan
......@@ -47,7 +48,7 @@ case $PMTYPE in
yum-rpm)
showcmd package-cleanup --orphans
local PKGLIST=$(package-cleanup --orphans)
sudocmd epm remove $PKGLIST
docmd epm remove $PKGLIST
;;
urpm-rpm)
showcmd urpmq --auto-orphans
......
......@@ -23,7 +23,8 @@ __epm_autoremove_altrpm()
load_helper epm-packages
assure_exists /etc/buildreqs/files/ignore.d/apt-scripts apt-scripts
info
info "Just removing all non -devel libs packages not need by anything..."
info "Removing all non -devel/-debuginfo libs packages not need by anything..."
[ -n "$force" ] || info "You can run with --force for more deep removing"
local flag=
local libexclude='^lib'
......@@ -32,11 +33,13 @@ __epm_autoremove_altrpm()
# https://www.altlinux.org/APT_в_ALT_Linux/Советы_по_использованию#apt-cache_list-nodeps
showcmd "apt-cache list-nodeps | grep -- \"$libexclude\""
pkgs=$(apt-cache list-nodeps | grep -- "$libexclude" | \
grep -v -- "-devel$" | grep -v -- "-debuginfo$" | \
grep -v -- "-util" | grep -v -- "-tool" | grep -v -- "-plugin" | \
grep -v -- ^libreoffice | grep -v -- libnss- )
grep -E -v -- "-(devel|debuginfo)$" | \
grep -E -v -- "-(util|tool|plugin|daemon)" | \
sed -e "s/\.32bit$//g" | \
grep -E -v -- "^(libsystemd|libreoffice|libnss)" )
[ -n "$pkgs" ] && sudocmd rpm -v -e $pkgs && flag=1
info "Removing unused python/perl modules..."
libexclude='^(python-module-|python3-module-|python-modules-|python3-modules|perl-)'
[ -n "$force" ] || libexclude=$libexclude'[^-]*$'
showcmd "apt-cache list-nodeps | grep -E -- \"$libexclude\""
......@@ -44,7 +47,8 @@ __epm_autoremove_altrpm()
[ -n "$pkgs" ] && sudocmd rpm -v -e $pkgs && flag=1
if [ -n "$flag" ] ; then
info "call again for next cycle until all libs will removed"
info ""
info "call again for next cycle until all libs will be removed"
__epm_autoremove_altrpm
fi
......@@ -64,7 +68,7 @@ case $PMTYPE in
__epm_autoremove_altrpm
# ALT Linux only
assure_exists remove-old-kernels
assure_exists remove-old-kernels update-kernel 0.9.9
sudocmd remove-old-kernels
;;
apt-dpkg|aptitude-dpkg)
......
# This spec is backported to ALTLinux p8 automatically by rpmbph script from etersoft-build-utils.
#
Name: eepm
Version: 1.8.2
Version: 1.8.3
Release: alt0.M80P.1
Summary: Etersoft EPM package manager
......@@ -67,9 +67,14 @@ chmod a+x %buildroot%_datadir/%name/{serv-,epm-}*
%_sysconfdir/bash_completion.d/cerv
%changelog
* Fri May 20 2016 Vitaly Lipatov <lav@altlinux.ru> 1.8.2-alt0.M80P.1
* Mon May 23 2016 Vitaly Lipatov <lav@altlinux.ru> 1.8.3-alt0.M80P.1
- backport to ALTLinux p8 (by rpmbph script)
* Mon May 23 2016 Vitaly Lipatov <lav@altlinux.ru> 1.8.3-alt1
- autoorphans: do real removing
- autoremove: add update-kernel version 0.9.9 checking
- autoorphans/autoremove: improve excludes
* Fri May 20 2016 Vitaly Lipatov <lav@altlinux.ru> 1.8.2-alt1
- epm_install: added command for install or update eepm package from all in one script
- add --no-remove support during upgrade
......
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