arethusa-cli 0.1.5 → 0.1.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/arethusa/cli/version.rb +1 -1
- data/lib/arethusa/cli.rb +6 -2
- 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: 37d7f500edfe6b324176165c6f23b0092bddb22a
|
4
|
+
data.tar.gz: e731f8b468c1659a86de8da2bf29543b86d87ba0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 50ab1a100438525355ef1b87a864fb09a6d5e6e7b6156f8fd78ff10873e384ab010d9f46a072eda304a5eed6b463bb72a4cccae669f4ba837d3bb604ec3dcf3b
|
7
|
+
data.tar.gz: e073dde397f4b6768f5ad873bb2a185beb845723aface295a8782440eee322f39774b68da7dbf1a25ef3cdfdf57e7df4f19fbe9b54516376c89c91e81001b267
|
data/lib/arethusa/cli/version.rb
CHANGED
data/lib/arethusa/cli.rb
CHANGED
@@ -55,11 +55,15 @@ EOF
|
|
55
55
|
desc: 'Minifies Arethusa before building'
|
56
56
|
method_option :commit, aliases: '-c', type: :boolean,
|
57
57
|
desc: 'Deploy in a subfolder, referenced by the current commit sha'
|
58
|
+
method_option :sudo, aliases: '-s', type: :boolean,
|
59
|
+
desc: 'Run ssh commands as sudo'
|
60
|
+
mo
|
58
61
|
def deploy(address, directory)
|
59
62
|
@address = address
|
60
63
|
@directory = options[:commit] ? File.join(directory, short_sha) : directory
|
61
64
|
@ssh_options = options[:options]
|
62
65
|
@archive = options[:file]
|
66
|
+
@sudo = options[:sudo] ? 'sudo ' : ''
|
63
67
|
|
64
68
|
@small = options[:small]
|
65
69
|
|
@@ -160,8 +164,8 @@ EOF
|
|
160
164
|
|
161
165
|
# For deploy command
|
162
166
|
def execute
|
163
|
-
`#{ssh} mkdir -p #{@directory}`
|
164
|
-
`#{archive_to_use} | #{ssh} #{decompress}`
|
167
|
+
`#{ssh} #{@sudo} mkdir -p #{@directory}`
|
168
|
+
`#{archive_to_use} | #{ssh} #{@sudo} #{decompress}`
|
165
169
|
end
|
166
170
|
|
167
171
|
def compress
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: arethusa-cli
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- LFDM
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-11-
|
11
|
+
date: 2014-11-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|