Commit 8ebc1c2d authored by Vitaly Lipatov's avatar Vitaly Lipatov

backported to p7 as 1.5.17-alt0.M70P.1 (with rpmbph script)

parents 1841bca5 f956f29b
...@@ -35,7 +35,7 @@ __epm_changelog_files() ...@@ -35,7 +35,7 @@ __epm_changelog_files()
case $(get_package_type $1) in case $(get_package_type $1) in
rpm) rpm)
assure_exists rpm assure_exists rpm
docmd_foreach "rpm -p --changelog" $@ | less docmd_foreach "rpm -q -p --changelog" $@ | less
;; ;;
# deb) # deb)
# #
...@@ -52,7 +52,7 @@ __epm_changelog_local_names() ...@@ -52,7 +52,7 @@ __epm_changelog_local_names()
case $PMTYPE in case $PMTYPE in
apt-rpm|yum-rpm|dnf-rpm|urpm-rpm|zypper-rpm) apt-rpm|yum-rpm|dnf-rpm|urpm-rpm|zypper-rpm)
docmd_foreach "rpm --changelog" $@ | less docmd_foreach "rpm -q --changelog" $@ | less
;; ;;
apt-dpkg|aptitude-dpkg) apt-dpkg|aptitude-dpkg)
docmd zcat /usr/share/doc/$1/changelog.Debian.gz | less docmd zcat /usr/share/doc/$1/changelog.Debian.gz | less
......
...@@ -17,15 +17,31 @@ ...@@ -17,15 +17,31 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>. # along with this program. If not, see <http://www.gnu.org/licenses/>.
# #
__is_repo_info_download() __is_repo_info_downloaded()
{ {
case $PMTYPE in case $PMTYPE in
apt-*) apt-*)
if [ -r /var/cache/apt ] ; then if [ -r /var/cache/apt ] ; then
# FIXME: only if root permissions # FIXME: only if root permissions, now skip for user
test -r /var/cache/apt/pkgcache.bin || return
fi
;;
*)
;;
esac
return 0
}
__is_repo_info_uptodate()
{
case $PMTYPE in
apt-*)
if [ -r /var/cache/apt ] ; then
# FIXME: only if root permissions, now skip for user
test -r /var/cache/apt/pkgcache.bin || return test -r /var/cache/apt/pkgcache.bin || return
# if repo older than 1 day, return false # if repo older than 1 day, return false
test -n "$(find /var/cache/apt/pkgcache.bin -ctime +1)" || return # find print string if file is obsoleted
test -z "$(find /var/cache/apt/pkgcache.bin -mtime +1)" || return
fi fi
;; ;;
*) *)
...@@ -36,12 +52,10 @@ __is_repo_info_download() ...@@ -36,12 +52,10 @@ __is_repo_info_download()
update_repo_if_needed() update_repo_if_needed()
{ {
if ! __is_repo_info_download ; then if ! __is_repo_info_downloaded || ! __is_repo_info_uptodate ; then
load_helper epm-update load_helper epm-update
epm_update epm_update
return return
fi fi
# TODO: if repo info is very obsoleted (a few days?), we need run update
} }
...@@ -283,7 +283,7 @@ set_eatmydata() ...@@ -283,7 +283,7 @@ set_eatmydata()
# use if possible # use if possible
which eatmydata >/dev/null 2>/dev/null || return which eatmydata >/dev/null 2>/dev/null || return
SUDO="$SUDO eatmydata" SUDO="$SUDO eatmydata"
info "Uwaga! eatmydata is installed, we will use it for disable all sync operations." [ -n "$verbose" ] && info "Uwaga! eatmydata is installed, we will use it for disable all sync operations."
return 0 return 0
} }
......
# This spec is backported to ALTLinux p7 automatically by rpmbph script. Do not edit it. # This spec is backported to ALTLinux p7 automatically by rpmbph script. Do not edit it.
# #
Name: eepm Name: eepm
Version: 1.5.16 Version: 1.5.17
Release: alt0.M70P.1 Release: alt0.M70P.1
Summary: Etersoft EPM package manager Summary: Etersoft EPM package manager
...@@ -67,9 +67,14 @@ chmod a+x %buildroot%_datadir/%name/{serv-,epm-}* ...@@ -67,9 +67,14 @@ chmod a+x %buildroot%_datadir/%name/{serv-,epm-}*
%_sysconfdir/bash_completion.d/cerv %_sysconfdir/bash_completion.d/cerv
%changelog %changelog
* Sun Aug 16 2015 Vitaly Lipatov <lav@altlinux.ru> 1.5.16-alt0.M70P.1 * Wed Aug 19 2015 Vitaly Lipatov <lav@altlinux.ru> 1.5.17-alt0.M70P.1
- backport to ALTLinux p7 (by rpmbph script) - backport to ALTLinux p7 (by rpmbph script)
* Wed Aug 19 2015 Vitaly Lipatov <lav@altlinux.ru> 1.5.17-alt1
- fix update repo checking
- print Uwaga about eatmydata only if verbose mode
- changelog: use query rpm mode for --changelog
* Sun Aug 16 2015 Vitaly Lipatov <lav@altlinux.ru> 1.5.16-alt1 * Sun Aug 16 2015 Vitaly Lipatov <lav@altlinux.ru> 1.5.16-alt1
- run update if repo info older than 1 day - run update if repo info older than 1 day
- epm-query_file: fix read link - epm-query_file: fix read link
......
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