coral_backup 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/coral_backup/cli.rb +8 -8
- data/lib/coral_backup/file_selector.rb +9 -6
- data/lib/coral_backup/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4805d6ac74e7cdeaaad6be240d574fbed59d3090
|
4
|
+
data.tar.gz: 67127b0f482f26bbd498dd94ff0be00a34321d39
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0ce618630fbc5f7da2f8d604df7c6f238b8fbcd16b06947a0692352699a04a551162a495e7df801270baa4dda216cb4e8a2d2ec973fb719bfffb8c34ab384d93
|
7
|
+
data.tar.gz: a63560f860be3f75c00e60227e4e391cc3dde36f4700d6cf356757d608808ea857baff991726a4061cab278e41322216ddad239927e8e06b29318b450d8f3553
|
data/lib/coral_backup/cli.rb
CHANGED
@@ -22,14 +22,6 @@ module CoralBackup
|
|
22
22
|
end
|
23
23
|
source << "/" unless source.end_with?("/")
|
24
24
|
|
25
|
-
puts "Drag and drop or input destination directory."
|
26
|
-
destination = FileSelector.single_select
|
27
|
-
unless FileTest.directory?(destination)
|
28
|
-
warn "ERROR: Not a directory: #{destination}"
|
29
|
-
exit 1
|
30
|
-
end
|
31
|
-
destination << "/" unless destination.end_with?("/")
|
32
|
-
|
33
25
|
puts "Drag and drop or input exclusion files/directories."
|
34
26
|
puts "Press Ctrl + D to finish."
|
35
27
|
exclusions = FileSelector.select
|
@@ -41,6 +33,14 @@ module CoralBackup
|
|
41
33
|
}
|
42
34
|
exclusions.uniq!
|
43
35
|
|
36
|
+
puts "Drag and drop or input destination directory."
|
37
|
+
destination = FileSelector.single_select
|
38
|
+
unless FileTest.directory?(destination)
|
39
|
+
warn "ERROR: Not a directory: #{destination}"
|
40
|
+
exit 1
|
41
|
+
end
|
42
|
+
destination << "/" unless destination.end_with?("/")
|
43
|
+
|
44
44
|
@settings.add(action_name, source, destination, exclusions)
|
45
45
|
end
|
46
46
|
|
@@ -46,12 +46,15 @@ module CoralBackup
|
|
46
46
|
while !file_added && buf = Readline.readline("> ")
|
47
47
|
expanded = Shellwords.split(buf)
|
48
48
|
warn "WARNING: #{expanded.length} files are being added:" unless expanded.length == 1
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
49
|
+
expanded.each do |ex|
|
50
|
+
begin
|
51
|
+
file_selector.add_file(ex)
|
52
|
+
rescue Errno::ENOENT => e
|
53
|
+
warn e
|
54
|
+
else
|
55
|
+
warn ex
|
56
|
+
file_added = true
|
57
|
+
end
|
55
58
|
end
|
56
59
|
end
|
57
60
|
|
data/lib/coral_backup/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: coral_backup
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- OTSUKA Tatsuya
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-06-
|
11
|
+
date: 2015-06-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: thor
|