rsyncbackup 2.0.0 → 2.0.1

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 10705744d2cfcaeb5a89c60a0d772bd951ebd050
4
- data.tar.gz: 8493e1056587694f144b1b98c388adb979a9d3e4
3
+ metadata.gz: 5f1596ffc77f401908dae8ed0cae815e56720665
4
+ data.tar.gz: a362a37ecf71f1427e06d349ecbf8a40ff15a29a
5
5
  SHA512:
6
- metadata.gz: fa458bbd4495d0f0a6463eedd7f5a0d1787def95da6eb0e3e88f2a3a8aeeb42bc4853273589765ed37945f4f9b899da6ee8f3b0b921a42af6f2518270736d2f9
7
- data.tar.gz: f37280db214a6999552deb96472785537fc93dea5665d2153f89f6bbddb2caf39ac659c8417ff61cb263a33691d5ad6a3294bf11ce3fb8d83db4be2d079590e6
6
+ metadata.gz: 1ec7c869069858f94f1a555c8bc8f1c6c0f44f08e08921bb9cf8a958ece1f73412491638c66b56bc5049daa971d00fa059189e3a82b7df4dd29e1b4194e147fd
7
+ data.tar.gz: 75dad458110c68f0bf38060e6e7245d18bca48d8cdb552d59c6543ab7109cfc5867f5f6294017c1865d42db25ad1c77faad987b403c1194a9bc0ec83debe74dd
data/Guardfile CHANGED
@@ -2,6 +2,7 @@ guard 'cucumber', :cli => '--color --format pretty' do
2
2
  watch(%r{^features/.+\.feature$})
3
3
  watch(%r{^features/support/.+$}) { 'features' }
4
4
  watch(%r{^features/step_definitions/(.+)_steps\.rb$}) { |m| Dir[File.join("**/#{m[1]}.feature")][0] || 'features' }
5
+ watch(%r{^bin/*}) {"features"}
5
6
  end
6
7
 
7
8
  guard :rspec, :cli => "--color --format documentation --fail-fast" do
data/bin/rsyncbackup CHANGED
@@ -1,6 +1,5 @@
1
1
  #!/usr/bin/env ruby
2
2
 
3
- require 'optparse'
4
3
  require 'methadone'
5
4
  require 'rsyncbackup'
6
5
 
@@ -9,9 +8,24 @@ class App
9
8
  include Methadone::CLILogging
10
9
 
11
10
  main do |source, target|
12
- syncer = Rsyncbackup.new(source, target, options)
13
- syncer.run
14
- syncer.finalize
11
+ logger.level = Logger::WARN
12
+ logger.level = Logger::INFO if options[:verbose]
13
+ logger.error_level = Logger::DEBUG if options[:debug]
14
+ begin
15
+ syncer = Rsyncbackup.new(source, target, options)
16
+ o, e, s = syncer.run
17
+ syncer.finalize
18
+ if s.success?
19
+ info o
20
+ else
21
+ error e
22
+ end
23
+ rescue RuntimeError => e
24
+ error "Error occured in rsyncbackup: #{e.class} #{e}"
25
+ debug "Backtrace:\n#{e.backtrace}"
26
+ exit 127
27
+ end
28
+ s.exitstatus
15
29
  end
16
30
 
17
31
  description "Yet another rsync backup script, this time in ruby"
@@ -26,7 +40,5 @@ class App
26
40
 
27
41
  version Rsyncbackup::VERSION
28
42
 
29
- # use_log_level_option
30
-
31
43
  go!
32
44
  end
@@ -1,5 +1,5 @@
1
1
  class Rsyncbackup
2
- VERSION = "2.0.0"
2
+ VERSION = "2.0.1"
3
3
  DEFAULT_EXCLUSIONS = File.expand_path('.rsyncbackup.exclusions', ENV['HOME'])
4
4
  DEFAULT_INCOMPLETE_DIR_NAME = '.incomplete'
5
5
  DEFAULT_LAST_FULL_DIR_NAME = '.lastfull'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rsyncbackup
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tamara Temple