[packages/etckeeper] up to 0.64, add -bzr subpackage, cleanups

glen glen at pld-linux.org
Sat May 4 14:43:32 CEST 2013


commit b11a8e3fd7424cf18a021fc6afdca0ce267ac4fe
Author: Elan Ruusamäe <glen at delfi.ee>
Date:   Sat May 4 15:39:42 2013 +0300

    up to 0.64, add -bzr subpackage, cleanups

 etckeeper.spec | 51 ++++++++++++++++++++++++++++++++++++++-------------
 1 file changed, 38 insertions(+), 13 deletions(-)
---
diff --git a/etckeeper.spec b/etckeeper.spec
index d7963ea..3363eda 100644
--- a/etckeeper.spec
+++ b/etckeeper.spec
@@ -3,14 +3,14 @@
 # - Subpackages for backends (git, bzr, etc)
 # - Write PLD %pre and %post macros that trigger pre-install and post-install runs
 # - %{py_sitescriptdir}/bzrlib/plugins also created by qbzr package?
-Summary:	Store /etc in git, mercurial, bzr or darcs
+Summary:	Store /etc in a SCM system (git, mercurial, bzr or darcs)
 Name:		etckeeper
-Version:	0.62
+Version:	0.64
 Release:	0.1
 License:	GPL v2
 Group:		Applications/System
 Source0:	http://ftp.debian.org/debian/pool/main/e/etckeeper/%{name}_%{version}.tar.gz
-# Source0-md5:	4b7738882f425c6bae7c99daa965e1de
+# Source0-md5:	ddd3229028df8da9af03ec8128cebc9b
 URL:		http://kitenet.net/~joey/code/etckeeper/
 BuildRequires:	bzr
 BuildRequires:	rpm-pythonprov
@@ -19,14 +19,14 @@ BuildRequires:	sed >= 4.0
 Requires:	perl
 Requires:	python-modules
 Suggests:	%{name}-bash-completions
+Suggests:	%{name}-bzr
 Suggests:	git-core >= 1.6.1-1
-Obsoletes:	etckeeper = snapshot
 Obsoletes:	yum-etckeeper
 BuildArch:	noarch
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
-The %{name} program is a tool to let /etc be stored in a git,
+The etckeeper program is a tool to let /etc be stored in a git,
 mercurial, bzr or darcs repository. It hooks into APT to automatically
 commit changes made to /etc during package upgrades. It tracks file
 metadata that version control systems do not normally support, but
@@ -34,6 +34,23 @@ that is important for /etc, such as the permissions of /etc/shadow.
 It's quite modular and configurable, while also being simple to use if
 you understand the basics of working with version control.
 
+The default backend is git, if want to use a another backend please
+install the appropriate tool (mercurial, darcs or bzr). To use bzr as
+backend, please also install the %{name}-bzr package.
+
+To start using the package please read
+%{_docdir}/%{name}-%{version}/README
+
+%package bzr
+Summary:	Support for bzr with etckeeper
+Group:		Applications/System
+Requires:	%{name} = %{version}-%{release}
+Requires:	bzr
+
+%description bzr
+This package provides a bzr backend for etckeeper, if you want to use
+etckeeper with bzr backend, install this package.
+
 %package bash-completions
 Summary:	Bash completion routies for %{name}
 Group:		Applications/Shells
@@ -45,7 +62,6 @@ Bash completion routines for %{name}
 
 %prep
 %setup -q -n %{name}
-
 %{__sed} -i -e '
 	s|HIGHLEVEL_PACKAGE_MANAGER=apt|HIGHLEVEL_PACKAGE_MANAGER=poldek|;
 	s|LOWLEVEL_PACKAGE_MANAGER=dpkg|LOWLEVEL_PACKAGE_MANAGER=rpm|;
@@ -56,8 +72,9 @@ Bash completion routines for %{name}
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT/etc/cron.daily
+install -d $RPM_BUILD_ROOT{/etc/cron.daily,%{_localstatedir}/cache/%{name}}
 %{__make} install \
+	INSTALL="install -p" \
 	DESTDIR=$RPM_BUILD_ROOT
 
 install -p debian/cron.daily $RPM_BUILD_ROOT/etc/cron.daily/%{name}
@@ -69,10 +86,16 @@ install -p debian/cron.daily $RPM_BUILD_ROOT/etc/cron.daily/%{name}
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+%if 0
+%post
+if [ $1 -gt 1 ] ; then
+	%{_bindir}/%{name} update-ignore
+fi
+%endif
+
 %files
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_bindir}/%{name}
-
+%doc INSTALL TODO README
 %dir %{_sysconfdir}/%{name}
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/%{name}.conf
 %dir %{_sysconfdir}/%{name}/*.d
@@ -80,14 +103,16 @@ rm -rf $RPM_BUILD_ROOT
 %{_sysconfdir}/%{name}/*.d/README
 
 %attr(755,root,root) /etc/cron.daily/%{name}
+%attr(755,root,root) %{_bindir}/%{name}
+%{_mandir}/man8/%{name}.8*
 
+%files bzr
+%defattr(644,root,root,755)
 %dir %{py_sitescriptdir}/bzrlib
 %dir %{py_sitescriptdir}/bzrlib/plugins
 %dir %{py_sitescriptdir}/bzrlib/plugins/%{name}
-%{py_sitescriptdir}/bzrlib/plugins/%{name}/__init__.py[co]
-
-%doc INSTALL TODO README
-%{_mandir}/man8/%{name}.8*
+%{py_sitescriptdir}/bzrlib/plugins/%{name}/*.py[co]
+%{py_sitescriptdir}/bzr_etckeeper-*.egg-info
 
 %files bash-completions
 %defattr(644,root,root,755)
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/etckeeper.git/commitdiff/04edd6125da8a5036d04fa23c7e80dbd3429f0eb



More information about the pld-cvs-commit mailing list