loft-harmony 1.2.1 → 1.2.2
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/harmony +10 -2
- 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: df76af79bda66a3cc2b48282f7d0c31586e143b3
|
4
|
+
data.tar.gz: 174090be91e9ccedc3e4566792586bbf6265c95b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 266bf609aed5a29318bc686a262cebff45d8baf6bdf6eed09cc4a5b2279ad4d11278e7221f1c6fcf072d14545c08552aeb18066ae373eec9c443bd06414c1a4c
|
7
|
+
data.tar.gz: af25de5487c71f06c76d4b057f9db51e248675f5d563ba44545b7e186fc213b9df75413b808fc9a5af8bcdd80bd3867272463fa522951068a928c2caddf1c134
|
data/bin/harmony
CHANGED
@@ -18,6 +18,7 @@ class Harmony < TerminalRunner
|
|
18
18
|
option "--eco", 2, "target identifier", "Automatically compile saved eco files to the given directory."
|
19
19
|
option "--auto", 0, "", "Start up auto mode automatically."
|
20
20
|
option "--passive", 0, "", "Use FTP in passive mode."
|
21
|
+
option "--vanilla_ftp", 0, "", "Use Vanilla ruby Net::FTP. Disables automatica directory creation."
|
21
22
|
|
22
23
|
help ""
|
23
24
|
|
@@ -38,6 +39,7 @@ class Harmony < TerminalRunner
|
|
38
39
|
@timeout = @@options.include?("--timeout") ? @@options["--timeout"][0].to_i : 2
|
39
40
|
@compile_coffeescript = @@options.include?("--coffee") ? @@options["--coffee"][0] : nil
|
40
41
|
@passive_mode = @@options.include?("--passive")
|
42
|
+
@use_vanilla_ftp = @@options.include?("--vanilla_ftp")
|
41
43
|
@ignored = []
|
42
44
|
|
43
45
|
@compile_eco = nil
|
@@ -160,7 +162,7 @@ class Harmony < TerminalRunner
|
|
160
162
|
Timeout::timeout(@timeout) do
|
161
163
|
rpath = self.remote_path_for(file)
|
162
164
|
|
163
|
-
if @ftp.mkdir_p rpath
|
165
|
+
if @ftp.respond_to?(:mkdir_p) && @ftp.mkdir_p(rpath)
|
164
166
|
puts " ## Created new directory #{rpath}".pink
|
165
167
|
end
|
166
168
|
|
@@ -237,8 +239,14 @@ class Harmony < TerminalRunner
|
|
237
239
|
|
238
240
|
if @ftp.nil? || @ftp.closed?
|
239
241
|
puts " ## Connection opening".red
|
240
|
-
|
242
|
+
if @use_vanilla_ftp
|
243
|
+
puts "(Using Vanilla FTP)".pink
|
244
|
+
@ftp = Net::FTP.new(@server, @user, @password)
|
245
|
+
else
|
246
|
+
@ftp = BetterFTP.new(@server, @user, @password)
|
247
|
+
end
|
241
248
|
@ftp.passive = @passive_mode
|
249
|
+
puts "(Using Passive Mode)".pink if @passive_mode
|
242
250
|
end
|
243
251
|
end
|
244
252
|
true
|