backupgem 0.0.9 → 0.0.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,21 @@
1
+ require 'fileutils'
2
+
3
+ class StateRecorder
4
+ attr_accessor :sons_since_last_promotion
5
+ attr_accessor :fathers_since_last_promotion
6
+ attr_accessor :saved_state_folder
7
+
8
+ def initialize
9
+ @sons_since_last_promotion = 0
10
+ @fathers_since_last_promotion = 0
11
+ end
12
+
13
+ # cleanup all the snapshots created by madeline
14
+ def cleanup_snapshots
15
+ files = Dir[saved_state_folder + "/*.snapshot"]
16
+ files.pop
17
+ files.sort.each do |f|
18
+ FileUtils.rm(f, :verbose => false)
19
+ end
20
+ end
21
+ end
@@ -0,0 +1,2 @@
1
+ #!/usr/bin/bash
2
+ LOOK_IN="/var/local/backups/mediawiki/sons"; COUNT=`ls -1 $LOOK_IN | wc -l`; MAX=14; if (( $COUNT > $MAX )); then let "OFFSET=$COUNT-$MAX"; i=1; for f in `ls -1 $LOOK_IN | sort`; do if (( $i <= $OFFSET )); then CMD="rm $LOOK_IN/$f"; echo $CMD; $CMD; fi; echo "$i $f"; let "i=$i + 1"; done; else true; fi
@@ -0,0 +1,5 @@
1
+ $:.unshift File.dirname(__FILE__) + "/../lib"
2
+
3
+ require 'test/unit'
4
+ require 'backup'
5
+ require 'backup/extensions'
metadata CHANGED
@@ -3,8 +3,8 @@ rubygems_version: 0.9.4
3
3
  specification_version: 1
4
4
  name: backupgem
5
5
  version: !ruby/object:Gem::Version
6
- version: 0.0.9
7
- date: 2007-08-06 00:00:00 -07:00
6
+ version: 0.0.11
7
+ date: 2007-08-07 00:00:00 -07:00
8
8
  summary: Beginning-to-end solution for backups and rotation.
9
9
  require_paths:
10
10
  - lib
@@ -29,8 +29,36 @@ post_install_message:
29
29
  authors:
30
30
  - Nate Murray
31
31
  files:
32
- - doc/LICENSE-GPL.txt
32
+ - bin/backup
33
+ - bin/commands.sh
34
+ - lib/backup
35
+ - lib/backup/actor.rb
36
+ - lib/backup/actor.rb.orig
37
+ - lib/backup/cli.rb
38
+ - lib/backup/configuration.rb
39
+ - lib/backup/date_parser.rb
40
+ - lib/backup/extensions.rb
41
+ - lib/backup/recipes
42
+ - lib/backup/recipes/standard.rb
43
+ - lib/backup/rotator.rb
44
+ - lib/backup/s3_helpers.rb
45
+ - lib/backup/ssh_helpers.rb
46
+ - lib/backup/state_recorder.rb
47
+ - lib/backup.rb
48
+ - tests/actor_test.rb
49
+ - tests/cleanup.sh
50
+ - tests/optional
51
+ - tests/optional/s3_test.rb
52
+ - tests/rotation_test.rb
53
+ - tests/s3_test.rb
54
+ - tests/ssh_test.rb
55
+ - tests/tests_helper.rb
56
+ - examples/global.rb
57
+ - examples/mediawiki.rb
58
+ - examples/mediawiki_numeric.rb
59
+ - examples/s3.rb
33
60
  - doc/index.html
61
+ - doc/LICENSE-GPL.txt
34
62
  - doc/styles.css
35
63
  - README
36
64
  - CHANGELOG