[packages/etckeeper] Up to 1.18.16. cron.daily is maintained in debian package only now (take it from here). Fix running

arekm arekm at pld-linux.org
Mon May 31 13:53:30 CEST 2021


commit 4dda49536403916778a27fabb3201e0d22925ed8
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date:   Mon May 31 13:52:58 2021 +0200

    Up to 1.18.16. cron.daily is maintained in debian package only now (take it from here). Fix running daily job (wasn't run at all).

 etckeeper.spec      | 11 ++++++++---
 update-ignore.patch |  2 +-
 use-libdir.patch    | 30 +++++++++++++++++-------------
 3 files changed, 26 insertions(+), 17 deletions(-)
---
diff --git a/etckeeper.spec b/etckeeper.spec
index 6bd7200..4a66783 100644
--- a/etckeeper.spec
+++ b/etckeeper.spec
@@ -3,14 +3,16 @@
 # - Subpackages for backends (darcs, git, hg)
 Summary:	Store /etc in a SCM system (git, mercurial, bzr or darcs)
 Name:		etckeeper
-Version:	1.18.14
+Version:	1.18.16
 Release:	1
 License:	GPL v2+
 Group:		Applications/System
 Source0:	https://git.joeyh.name/index.cgi/etckeeper.git/snapshot/%{name}-%{version}.tar.gz
-# Source0-md5:	16da85e787dccef11fcf32baddf47d79
+# Source0-md5:	3d1636d5b792a8e07d138060fd95cb02
 Source1:	pre-install.sh
 Source2:	post-install.sh
+Source3:	https://ftp.debian.org/debian/pool/main/e/etckeeper/etckeeper_1.18.16-1.debian.tar.xz
+# Source3-md5:	49849b13951d76dcb3c4015090a26511
 Patch1:		use-libdir.patch
 Patch2:		update-ignore.patch
 URL:		http://etckeeper.branchable.com/
@@ -78,9 +80,12 @@ Obsoletes:	etckeeper-bash-completions
 Bash completion routines for etckeeper.
 
 %prep
-%setup -q
+%setup -q -a3
 %patch1 -p1
 %patch2 -p1
+
+patch -p1 < debian/patches/0002-Default-to-UTF8-encoding-for-consistent-ordering.patch || exit 1
+
 %{__sed} -i -e '
 	s|HIGHLEVEL_PACKAGE_MANAGER=apt|HIGHLEVEL_PACKAGE_MANAGER=poldek|;
 	s|LOWLEVEL_PACKAGE_MANAGER=dpkg|LOWLEVEL_PACKAGE_MANAGER=rpm|;
diff --git a/update-ignore.patch b/update-ignore.patch
index 231b72e..88e72fd 100644
--- a/update-ignore.patch
+++ b/update-ignore.patch
@@ -1,8 +1,8 @@
 --- etckeeper-1.10/update-ignore.d/01update-ignore	2013-11-14 15:33:56.904100141 +0200
 +++ etckeeper-1.10/update-ignore.d/01update-ignore	2014-02-03 11:58:25.578526063 +0000
 @@ -146,11 +145,80 @@
- 	ignore "cups/subscriptions.conf.O"
  	ignore "fake-hwclock.data"
+	ignore "check_mk/logwatch.state"
  	nl
 +
 +	comment "PLD Linux addons"
diff --git a/use-libdir.patch b/use-libdir.patch
index 022dd60..4752846 100644
--- a/use-libdir.patch
+++ b/use-libdir.patch
@@ -12,7 +12,7 @@
  	ETCKEEPER_CONF_DIR=/etc/etckeeper
  fi
 @@ -84,8 +88,8 @@
- 	command=pre-install
+ 	exit 1
  fi
  
 -if [ ! -d "$ETCKEEPER_CONF_DIR/$command.d" ]; then
@@ -22,8 +22,8 @@
  	exit 1
  fi
  
-@@ -132,19 +132,20 @@
- if [ "$(which perl 2>/dev/null)" != "" ]; then
+@@ -128,19 +132,20 @@
+ if command -v perl >/dev/null; then
  	lsscripts() {
  		LANG=C perl -e '
 -			$dir=shift;
@@ -47,16 +47,6 @@
  		if [ ! -d "$script" -a -x "$script" ]; then
  			echo "$script" | egrep -q "/[-a-zA-Z0-9]+$"
  			[ $? -eq 0 ] && "$script" "$@"
---- etckeeper-1.18.4/debian/cron.daily~	2016-06-20 08:06:01.000000000 +0300
-+++ etckeeper-1.18.4/debian/cron.daily	2016-06-29 23:41:40.939927867 +0300
-@@ -3,6 +3,6 @@
- if [ -e /etc/etckeeper/daily ] && [ -e /etc/etckeeper/etckeeper.conf ]; then
- 	. /etc/etckeeper/etckeeper.conf
- 	if [ "$AVOID_DAILY_AUTOCOMMITS" != "1" ]; then
--		/etc/etckeeper/daily
-+		/lib/etckeeper/daily
- 	fi
- fi
 --- etckeeper-1.18.4/systemd/etckeeper.service~	2016-06-20 08:06:01.000000000 +0300
 +++ etckeeper-1.18.4/systemd/etckeeper.service	2016-06-29 23:42:00.804296507 +0300
 @@ -8,5 +8,5 @@
@@ -66,3 +56,17 @@
 -ExecStart=/etc/etckeeper/daily
 +ExecStart=/lib/etckeeper/daily
  IOSchedulingClass=idle
+--- etckeeper-1.18.16/debian/cron.daily~	2021-05-31 13:29:39.000000000 +0200
++++ etckeeper-1.18.16/debian/cron.daily	2021-05-31 13:31:15.151417059 +0200
+@@ -1,8 +1,8 @@
+ #!/bin/sh
+ set -e
+-if [ -e /etc/etckeeper/daily ] && [ -e /etc/etckeeper/etckeeper.conf ]; then
++if [ -e /lib/etckeeper/daily ] && [ -e /etc/etckeeper/etckeeper.conf ]; then
+ 	. /etc/etckeeper/etckeeper.conf
+ 	if [ "$AVOID_DAILY_AUTOCOMMITS" != "1" ]; then
+-		/etc/etckeeper/daily
++		/lib/etckeeper/daily
+ 	fi
+ fi
+
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/etckeeper.git/commitdiff/4dda49536403916778a27fabb3201e0d22925ed8



More information about the pld-cvs-commit mailing list