photocopier 1.0.0.pre2 → 1.0.0.pre3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/.ruby-version +1 -1
- data/lib/photocopier/adapter.rb +0 -1
- data/lib/photocopier/ftp.rb +8 -5
- data/lib/photocopier/ssh.rb +1 -1
- data/lib/photocopier/version.rb +1 -1
- data/lib/photocopier.rb +2 -1
- data/photocopier.gemspec +2 -2
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fa357cb2a64be14d6d7a5249d5af142357ec88e8
|
4
|
+
data.tar.gz: 8fe84e099a21f74776a74979205ca1ca06cb68f6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 35b64e0dea575c624ed752ad6d118eada403565696dfb14f70538d6c8482c5e848e6285806f07f1214803db313a5a2f2ea9c250ecbda8174c4fb363163e90814
|
7
|
+
data.tar.gz: 8f5e6b6f69b551c328fd08adc54caac8a211446ab98662533aba513057463fd2145b484ec6e43d3e474e8ded6d5b420f481fbd3c33840c293fd7f5543546362c
|
data/.gitignore
CHANGED
data/.ruby-version
CHANGED
@@ -1 +1 @@
|
|
1
|
-
2.2.
|
1
|
+
2.2.2
|
data/lib/photocopier/adapter.rb
CHANGED
data/lib/photocopier/ftp.rb
CHANGED
@@ -41,12 +41,15 @@ module Photocopier
|
|
41
41
|
end
|
42
42
|
|
43
43
|
def lftp(local, remote, reverse, exclude)
|
44
|
+
remote = Shellwords.escape(remote)
|
45
|
+
local = Shellwords.escape(local)
|
44
46
|
command = [
|
45
47
|
"set ftp:list-options -a",
|
48
|
+
"set cmd:fail-exit true",
|
46
49
|
"open #{remote_ftp_url}",
|
47
|
-
"mkdir -p #{
|
48
|
-
"
|
49
|
-
"
|
50
|
+
"find -d 1 #{remote} || mkdir -p #{remote}",
|
51
|
+
"lcd #{local}",
|
52
|
+
"cd #{remote}",
|
50
53
|
lftp_mirror_arguments(reverse, exclude)
|
51
54
|
].join("; ")
|
52
55
|
|
@@ -66,10 +69,10 @@ module Photocopier
|
|
66
69
|
end
|
67
70
|
|
68
71
|
def lftp_mirror_arguments(reverse, exclude = [])
|
69
|
-
mirror = "mirror --delete --use-cache --verbose --allow-chown --allow-suid --no-umask --parallel=
|
72
|
+
mirror = "mirror --delete --use-cache --verbose --allow-chown --allow-suid --no-umask --parallel=5"
|
70
73
|
mirror << " --reverse" if reverse
|
71
74
|
exclude.each do |glob|
|
72
|
-
mirror << " --exclude-glob #{glob}"
|
75
|
+
mirror << " --exclude-glob #{glob}" # NOTE do not use Shellwords.escape here
|
73
76
|
end
|
74
77
|
mirror
|
75
78
|
end
|
data/lib/photocopier/ssh.rb
CHANGED
data/lib/photocopier/version.rb
CHANGED
data/lib/photocopier.rb
CHANGED
data/photocopier.gemspec
CHANGED
@@ -28,7 +28,7 @@ Gem::Specification.new do |spec|
|
|
28
28
|
|
29
29
|
spec.add_development_dependency "bundler", ">= 1.6.2"
|
30
30
|
spec.add_development_dependency "rake", "~> 10.0"
|
31
|
-
spec.add_development_dependency "rspec", "~> 3.
|
32
|
-
spec.add_development_dependency "simplecov", "~> 0.
|
31
|
+
spec.add_development_dependency "rspec", "~> 3.3"
|
32
|
+
spec.add_development_dependency "simplecov", "~> 0.10"
|
33
33
|
spec.add_development_dependency "pry-byebug", "~> 3.1"
|
34
34
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: photocopier
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.0.
|
4
|
+
version: 1.0.0.pre3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Stefano Verna
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: exe
|
12
12
|
cert_chain: []
|
13
|
-
date: 2015-
|
13
|
+
date: 2015-07-12 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: activesupport
|
@@ -102,28 +102,28 @@ dependencies:
|
|
102
102
|
requirements:
|
103
103
|
- - "~>"
|
104
104
|
- !ruby/object:Gem::Version
|
105
|
-
version: '3.
|
105
|
+
version: '3.3'
|
106
106
|
type: :development
|
107
107
|
prerelease: false
|
108
108
|
version_requirements: !ruby/object:Gem::Requirement
|
109
109
|
requirements:
|
110
110
|
- - "~>"
|
111
111
|
- !ruby/object:Gem::Version
|
112
|
-
version: '3.
|
112
|
+
version: '3.3'
|
113
113
|
- !ruby/object:Gem::Dependency
|
114
114
|
name: simplecov
|
115
115
|
requirement: !ruby/object:Gem::Requirement
|
116
116
|
requirements:
|
117
117
|
- - "~>"
|
118
118
|
- !ruby/object:Gem::Version
|
119
|
-
version: '0.
|
119
|
+
version: '0.10'
|
120
120
|
type: :development
|
121
121
|
prerelease: false
|
122
122
|
version_requirements: !ruby/object:Gem::Requirement
|
123
123
|
requirements:
|
124
124
|
- - "~>"
|
125
125
|
- !ruby/object:Gem::Version
|
126
|
-
version: '0.
|
126
|
+
version: '0.10'
|
127
127
|
- !ruby/object:Gem::Dependency
|
128
128
|
name: pry-byebug
|
129
129
|
requirement: !ruby/object:Gem::Requirement
|
@@ -188,7 +188,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
188
188
|
version: 1.3.1
|
189
189
|
requirements: []
|
190
190
|
rubyforge_project:
|
191
|
-
rubygems_version: 2.4.
|
191
|
+
rubygems_version: 2.4.8
|
192
192
|
signing_key:
|
193
193
|
specification_version: 4
|
194
194
|
summary: Photocopier provides FTP/SSH adapters to abstract away file and directory
|