Hello community, here is the log from the commit of package snapper for openSUSE:Factory checked in at Fri Jul 8 15:51:05 CEST 2011. -------- --- snapper/snapper.changes 2011-06-17 11:07:21.000000000 +0200 +++ /mounts/work_src_done/STABLE/snapper/snapper.changes 2011-06-28 12:51:50.000000000 +0200 @@ -1,0 +2,5 @@ +Tue Jun 28 11:46:28 CEST 2011 - aschnell@suse.de + +- added snapper-zypp-plugin subpackage (fate #308626) + +------------------------------------------------------------------- calling whatdependson for head-i586 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ snapper.spec ++++++ --- /var/tmp/diff_new_pack.92dei0/_old 2011-07-08 15:50:29.000000000 +0200 +++ /var/tmp/diff_new_pack.92dei0/_new 2011-07-08 15:50:29.000000000 +0200 @@ -20,15 +20,16 @@ Name: snapper Version: 0.0.6 -Release: 3 +Release: 5 License: GPL Group: System/Packages BuildRoot: %{_tmppath}/%{name}-%{version}-build Source: snapper-%{version}.tar.bz2 Prefix: /usr -BuildRequires: blocxx-devel boost-devel dejagnu doxygen gcc-c++ libxml2-devel +BuildRequires: boost-devel doxygen gcc-c++ libblocxx-devel libxml2-devel +BuildRequires: libzypp(plugin:commit) Requires: libsnapper1 = %version -Recommends: cron logrotate +Recommends: cron logrotate snapper-zypp-plugin Summary: Tool for filesystem snapshot management Url: http://en.opensuse.org/Portal:Snapper @@ -130,4 +131,22 @@ %{_libdir}/libsnapper.la %{_libdir}/libsnapper.so %{prefix}/include/snapper + +%package -n snapper-zypp-plugin + +Requires: snapper libzypp(plugin:commit) zypp-plugin-python +Summary: A zypp commit plugin for calling snapper +Group: System/Packages + +%description -n snapper-zypp-plugin +This package contains a plugin for zypp that makes filesystem snapshots with +snapper during commits. + +Authors: +-------- + Arvin Schnell <aschnell@suse.de> + +%files -n snapper-zypp-plugin +%defattr(-,root,root) +/usr/lib/zypp/plugins/commit/snapper.py %changelog ++++++ snapper-0.0.6.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapper-0.0.6/scripts/Makefile.am new/snapper-0.0.6/scripts/Makefile.am --- old/snapper-0.0.6/scripts/Makefile.am 2011-02-28 17:46:14.000000000 +0100 +++ new/snapper-0.0.6/scripts/Makefile.am 2011-06-28 11:46:02.000000000 +0200 @@ -2,9 +2,10 @@ # Makefile.am for snapper/scripts # -EXTRA_DIST = snapper-hourly snapper-daily +EXTRA_DIST = snapper-hourly snapper-daily zypp-plugin.py install-data-local: install -D snapper-hourly $(DESTDIR)/etc/cron.hourly/suse.de-snapper install -D snapper-daily $(DESTDIR)/etc/cron.daily/suse.de-snapper + install -D zypp-plugin.py $(DESTDIR)/usr/lib/zypp/plugins/commit/snapper.py diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapper-0.0.6/scripts/Makefile.in new/snapper-0.0.6/scripts/Makefile.in --- old/snapper-0.0.6/scripts/Makefile.in 2011-06-17 11:05:22.000000000 +0200 +++ new/snapper-0.0.6/scripts/Makefile.in 2011-07-08 14:17:44.000000000 +0200 @@ -176,7 +176,7 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -EXTRA_DIST = snapper-hourly snapper-daily +EXTRA_DIST = snapper-hourly snapper-daily zypp-plugin.py all: all-am .SUFFIXES: @@ -366,6 +366,7 @@ install-data-local: install -D snapper-hourly $(DESTDIR)/etc/cron.hourly/suse.de-snapper install -D snapper-daily $(DESTDIR)/etc/cron.daily/suse.de-snapper + install -D zypp-plugin.py $(DESTDIR)/usr/lib/zypp/plugins/commit/snapper.py # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapper-0.0.6/scripts/snapper-hourly new/snapper-0.0.6/scripts/snapper-hourly --- old/snapper-0.0.6/scripts/snapper-hourly 2011-03-07 11:06:22.000000000 +0100 +++ new/snapper-0.0.6/scripts/snapper-hourly 2011-06-29 11:28:42.000000000 +0200 @@ -33,7 +33,7 @@ . /etc/snapper/configs/$CONFIG if [ "$TIMELINE_CREATE" = "yes" ] ; then - snapper --config=$CONFIG --quiet create --description="timeline" --cleanup="timeline" + snapper --config=$CONFIG --quiet create --description="timeline" --cleanup-algorithm="timeline" fi done diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapper-0.0.6/scripts/zypp-plugin.py new/snapper-0.0.6/scripts/zypp-plugin.py --- old/snapper-0.0.6/scripts/zypp-plugin.py 1970-01-01 01:00:00.000000000 +0100 +++ new/snapper-0.0.6/scripts/zypp-plugin.py 2011-06-29 12:24:54.000000000 +0200 @@ -0,0 +1,29 @@ +#!/usr/bin/env python + +from os import readlink, getppid +from os.path import basename +from subprocess import Popen, PIPE +from zypp_plugin import Plugin + +class MyPlugin(Plugin): + + def PLUGINBEGIN(self, headers, body): + + exe = basename(readlink("/proc/%d/exe" % getppid())) + + args = ["snapper", "create", "--type=pre", "--print-number", + "--cleanup-algorithm=number", "--description=zypp(%s)" % exe] + self.o = Popen(args, stdout=PIPE).communicate()[0].strip() + + self.ack() + + def PLUGINEND(self, headers, body): + + args = ["snapper", "create", "--type=post", "--pre-number=%s" % self.o, + "--cleanup-algorithm=number"] + Popen(args) + + self.ack() + +plugin = MyPlugin() +plugin.main() diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapper-0.0.6/snapper/Snapper.cc new/snapper-0.0.6/snapper/Snapper.cc --- old/snapper-0.0.6/snapper/Snapper.cc 2011-06-17 11:05:06.000000000 +0200 +++ new/snapper-0.0.6/snapper/Snapper.cc 2011-06-29 16:13:47.000000000 +0200 @@ -177,7 +177,7 @@ bool invert = snapshot1->getNum() > snapshot2->getNum(); if (invert) - swap(snapshot1, snapshot1); + swap(snapshot1, snapshot2); string dir1 = snapshot1->snapshotDir(); string dir2 = snapshot2->snapshotDir(); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapper-0.0.6/snapper/Snapshot.cc new/snapper-0.0.6/snapper/Snapshot.cc --- old/snapper-0.0.6/snapper/Snapshot.cc 2011-04-26 14:23:03.000000000 +0200 +++ new/snapper-0.0.6/snapper/Snapshot.cc 2011-07-07 09:35:05.000000000 +0200 @@ -280,7 +280,10 @@ ++num; if (r != 0) + { + y2err("mkdir failed errno:" << errno << " (" << strerror(errno) << ")"); throw IOErrorException(); + } return num; } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapper-0.0.6/snapper.spec.in new/snapper-0.0.6/snapper.spec.in --- old/snapper-0.0.6/snapper.spec.in 2011-06-17 11:05:06.000000000 +0200 +++ new/snapper-0.0.6/snapper.spec.in 2011-07-04 16:20:45.000000000 +0200 @@ -11,9 +11,10 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build Source: snapper-%{version}.tar.bz2 Prefix: /usr -BuildRequires: gcc-c++ boost-devel blocxx-devel doxygen dejagnu libxml2-devel +BuildRequires: gcc-c++ boost-devel libblocxx-devel libxml2-devel doxygen +BuildRequires: libzypp(plugin:commit) Requires: libsnapper@LIBVERSION_MAJOR@ = %version -Recommends: cron logrotate +Recommends: cron logrotate snapper-zypp-plugin Summary: Tool for filesystem snapshot management Url: http://en.opensuse.org/Portal:Snapper @@ -113,3 +114,20 @@ %{_libdir}/libsnapper.la %{_libdir}/libsnapper.so %{prefix}/include/snapper + +%package -n snapper-zypp-plugin +Requires: snapper libzypp(plugin:commit) zypp-plugin-python +Summary: A zypp commit plugin for calling snapper +Group: System/Packages + +%description -n snapper-zypp-plugin +This package contains a plugin for zypp that makes filesystem snapshots with +snapper during commits. + +Authors: +-------- + Arvin Schnell <aschnell@suse.de> + +%files -n snapper-zypp-plugin +%defattr(-,root,root) +/usr/lib/zypp/plugins/commit/snapper.py diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapper-0.0.6/tools/snapper.cc new/snapper-0.0.6/tools/snapper.cc --- old/snapper-0.0.6/tools/snapper.cc 2011-06-17 11:05:06.000000000 +0200 +++ new/snapper-0.0.6/tools/snapper.cc 2011-07-07 17:30:41.000000000 +0200 @@ -310,7 +310,7 @@ { "pre-number", required_argument, 0, 0 }, { "description", required_argument, 0, 'd' }, { "print-number", no_argument, 0, 'p' }, - { "cleanup", required_argument, 0, 'c' }, + { "cleanup-algorithm", required_argument, 0, 'c' }, { 0, 0, 0, 0 } }; @@ -347,7 +347,7 @@ if ((opt = opts.find("print-number")) != opts.end()) print_number = true; - if ((opt = opts.find("cleanup")) != opts.end()) + if ((opt = opts.find("cleanup-algorithm")) != opts.end()) cleanup = opt->second; switch (type) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun... -- To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit+help@opensuse.org