Bug 90880 - pdumpfs-rsync updated
Summary: pdumpfs-rsync updated
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-ports-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-12-24 16:50 UTC by ota
Modified: 2005-12-26 01:37 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description ota 2005-12-24 16:50:03 UTC
            pdumpfs has been updated but corresponding changes are not made to pdumpfs-rsync so that it doesn't work.

Fix: The following patch includes the one in files dir, the first chunk.  Now, it runs and makes a backup as it says.  On the other hand, I didn't test file pattern matching part and don't know if it works.



-load '/usr/bin/pdumpfs'
+load File.join(File.dirname(__FILE__), 'pdumpfs')
 require 'ftools'
 require 'getoptlong'

@@ -128,8 +128,10 @@
     end
   end

-  latest = latest_snapshot(src, dest, base)
-  today  = File.join(dest, datedir(Date.today), base)
+  start_time = Time.now
+  pdumpfs = Pdumpfs::Pdumpfs.new(opts)
+  latest = pdumpfs.latest_snapshot(start_time, src, dest, base)
+  today = File.join(dest, pdumpfs.datedir(Date.today), base)
   rsync_array = rsync_array + rsync_opts
   rsync_array.push(ARGV[0].sub(%r!/+$!, '') + '/')
   rsync_array.push(src + '/')
@@ -141,7 +143,7 @@
     if ( $? >> 8 != 0 )
       STDERR.print "WARNING: rsync failed: #{ARGV[0]}; exit value: #{$? >> 8}\n
"
     end
-    update_snapshot(src, src, today, matcher)
+    pdumpfs.update_snapshot(src, src, today, matcher)
   else
     STDERR.print "rsync failed: #{ARGV[0]}; exit value: #{$? >> 8}\n"
     exit $? >> 8--R6xU0NtiN0i4o4XAd2yWEoVHcbSZWql3QoTC9ZfL1dHXuYhW
Content-Type: text/plain; name="file.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment; filename="file.diff"

--- pdumpfs-rsync.orig  Sat Dec 24 00:22:55 2005
+++ pdumpfs-rsync       Sat Dec 24 10:57:08 2005
@@ -15,7 +15,7 @@
 # the GNU General Public License version 2.
 #
How-To-Repeat:               pdumpfs-rsync host:source dist
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2005-12-26 01:37:04 UTC
State Changed
From-To: open->closed

Committed, thanks!