dropup 0.4 → 0.5
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 +4 -4
- data/bin/dropup +9 -10
- data/dropup.gemspec +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 223dcfde3ab9c1f5a3991c7a18b0a1ed7471606f
|
4
|
+
data.tar.gz: 6d89d60e2b2b47fb5a6d8adf868df401dccdbf5b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f8e1c4603921077ce3531f957586c466eaf59208c0a1c0bf9c0c76bd478097d99e989fb3e607ccac469b635ca034c1abc8a233b54bdc90ba5434eb8247059395
|
7
|
+
data.tar.gz: 4adbe28422f2818e02538e023ee01261809238a590fef88bc73c134ca79aaf3e4055a22b97be66e66c31912ad567c8dd1ff5c5a003ed33342647e1102103c5fd
|
data/bin/dropup
CHANGED
@@ -74,8 +74,7 @@ def backup(srcs, temp, password, size)
|
|
74
74
|
stdin.printf(password)
|
75
75
|
stdin.close
|
76
76
|
|
77
|
-
yield wait.value == 0
|
78
|
-
|
77
|
+
yield wait.value == 0 ? nil : stderr.read
|
79
78
|
end
|
80
79
|
end
|
81
80
|
|
@@ -92,14 +91,18 @@ end
|
|
92
91
|
temp = temp_pattern.gsub(/%/, time)
|
93
92
|
dest = dest_pattern.gsub(/%/, time)
|
94
93
|
|
94
|
+
TerminalNotifier.notify('Backup Starting') if options[:notification]
|
95
95
|
puts "Creating: #{dest}" if options[:verbose]
|
96
96
|
|
97
|
-
backup(ARGV, temp, password, options[:size]) do |
|
97
|
+
backup(ARGV, temp, password, options[:size]) do |error|
|
98
|
+
|
98
99
|
|
99
|
-
|
100
|
-
|
100
|
+
if error then
|
101
|
+
|
102
|
+
TerminalNotifier.notify('Backup Failed', :title => 'Error', :sound => 'default') if options[:notification]
|
103
|
+
puts "Error: #{error}" if options[:verbose]
|
101
104
|
|
102
|
-
|
105
|
+
else
|
103
106
|
|
104
107
|
TerminalNotifier.notify('Backup Successful', :title => 'Success') if options[:notification]
|
105
108
|
puts "Success" if options[:verbose]
|
@@ -114,9 +117,5 @@ backup(ARGV, temp, password, options[:size]) do |success|
|
|
114
117
|
|
115
118
|
FileUtils.move(temp, dest)
|
116
119
|
|
117
|
-
else
|
118
|
-
|
119
|
-
TerminalNotifier.notify('Backup Failed', :title => 'Error', :sound => 'default') if options[:notification]
|
120
|
-
puts "Error: #{stderr.read}" if options[:verbose]
|
121
120
|
end
|
122
121
|
end
|
data/dropup.gemspec
CHANGED