vagrant-shell-commander 0.3.0 → 0.3.1
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 +7 -0
- data/.travis.yml +1 -1
- data/Gemfile +5 -1
- data/Gemfile.lock +24 -6
- data/README.md +2 -9
- data/lib/vagrant-shell-commander/action.rb +2 -2
- data/lib/vagrant-shell-commander/version.rb +1 -1
- data/spec/action_spec.rb +6 -4
- data/spec/plugin_spec.rb +2 -3
- metadata +24 -46
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 15261a751e3748d72ae2854152b6d178f7b8067d
|
4
|
+
data.tar.gz: 157a84e1cf72f54af228156dd71b46b74118865c
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 32cb3646c609231e52928ed283f799f4cbba4221e72d44806c745d0bd6cc6e714cd9971690d74321fa039ebe2cc0b0de1a1ab24c466ec48e0956e0be0c90ebea
|
7
|
+
data.tar.gz: a22e56749097eb24220eedb05334acf34f101f56482499a2cec15e95bf8fefb8659539ba43034ac0466a6c979b8386208bb8c1767b9635047694cb79a27232d1
|
data/.travis.yml
CHANGED
data/Gemfile
CHANGED
@@ -4,5 +4,9 @@ source 'https://rubygems.org'
|
|
4
4
|
gemspec
|
5
5
|
|
6
6
|
group :development do
|
7
|
-
gem "vagrant", :git => "git://github.com/mitchellh/vagrant.git"
|
7
|
+
gem "vagrant", :git => "git://github.com/mitchellh/vagrant.git", tag: 'v1.5.1'
|
8
|
+
end
|
9
|
+
|
10
|
+
group :plugins do
|
11
|
+
gem "vagrant-shell-commander", path: "."
|
8
12
|
end
|
data/Gemfile.lock
CHANGED
@@ -1,31 +1,42 @@
|
|
1
1
|
GIT
|
2
2
|
remote: git://github.com/mitchellh/vagrant.git
|
3
|
-
revision:
|
3
|
+
revision: 6977e93ba98fd19112b1fed74dafb8619f581984
|
4
|
+
tag: v1.5.1
|
4
5
|
specs:
|
5
|
-
vagrant (1.5.
|
6
|
-
|
6
|
+
vagrant (1.5.1)
|
7
|
+
bundler (~> 1.5.2)
|
8
|
+
childprocess (~> 0.5.0)
|
7
9
|
erubis (~> 2.7.0)
|
8
10
|
i18n (~> 0.6.0)
|
9
|
-
|
11
|
+
listen (~> 2.4.0)
|
12
|
+
log4r (~> 1.1.9, < 1.1.11)
|
10
13
|
net-scp (~> 1.1.0)
|
11
14
|
net-ssh (>= 2.6.6, < 2.8.0)
|
15
|
+
rb-kqueue (~> 0.2.0)
|
16
|
+
wdm (~> 0.1.0)
|
12
17
|
|
13
18
|
PATH
|
14
19
|
remote: .
|
15
20
|
specs:
|
16
|
-
vagrant-shell-commander (0.3.
|
21
|
+
vagrant-shell-commander (0.3.1)
|
17
22
|
|
18
23
|
GEM
|
19
24
|
remote: https://rubygems.org/
|
20
25
|
specs:
|
21
26
|
cane (2.6.0)
|
22
27
|
parallel
|
23
|
-
|
28
|
+
celluloid (0.15.2)
|
29
|
+
timers (~> 1.1.0)
|
30
|
+
childprocess (0.5.1)
|
24
31
|
ffi (~> 1.0, >= 1.0.11)
|
25
32
|
diff-lcs (1.2.4)
|
26
33
|
erubis (2.7.0)
|
27
34
|
ffi (1.9.3)
|
28
35
|
i18n (0.6.9)
|
36
|
+
listen (2.4.1)
|
37
|
+
celluloid (>= 0.15.2)
|
38
|
+
rb-fsevent (>= 0.9.3)
|
39
|
+
rb-inotify (>= 0.9)
|
29
40
|
log4r (1.1.10)
|
30
41
|
multi_json (1.7.7)
|
31
42
|
net-scp (1.1.2)
|
@@ -33,6 +44,11 @@ GEM
|
|
33
44
|
net-ssh (2.7.0)
|
34
45
|
parallel (0.7.1)
|
35
46
|
rake (10.1.0)
|
47
|
+
rb-fsevent (0.9.4)
|
48
|
+
rb-inotify (0.9.3)
|
49
|
+
ffi (>= 0.5.0)
|
50
|
+
rb-kqueue (0.2.2)
|
51
|
+
ffi (>= 0.5.0)
|
36
52
|
reek (1.3.1)
|
37
53
|
ruby2ruby (~> 2.0.2)
|
38
54
|
ruby_parser (~> 3.1.1)
|
@@ -55,6 +71,8 @@ GEM
|
|
55
71
|
multi_json (~> 1.0)
|
56
72
|
simplecov-html (~> 0.7.1)
|
57
73
|
simplecov-html (0.7.1)
|
74
|
+
timers (1.1.0)
|
75
|
+
wdm (0.1.0)
|
58
76
|
yard (0.8.6.2)
|
59
77
|
|
60
78
|
PLATFORMS
|
data/README.md
CHANGED
@@ -14,15 +14,6 @@ Given you have Vagrant 1.1+ installed, as usual with vagrant plugins:
|
|
14
14
|
|
15
15
|
$ vagrant plugin install vagrant-shell-commander
|
16
16
|
|
17
|
-
or with the great Bindler, after adding a plugins.json with, at least:
|
18
|
-
|
19
|
-
{
|
20
|
-
"vagrant-shell-commander"
|
21
|
-
}
|
22
|
-
|
23
|
-
execute:
|
24
|
-
|
25
|
-
$ vagrant plugin bundle
|
26
17
|
|
27
18
|
## Usage
|
28
19
|
|
@@ -57,6 +48,8 @@ Vagrant.configure("2") do |config|
|
|
57
48
|
end
|
58
49
|
```
|
59
50
|
|
51
|
+
This can be handy if, for example, you want an application to start on boot and the application's code is in a synced folder.
|
52
|
+
|
60
53
|
## Contributing
|
61
54
|
|
62
55
|
1. Fork it
|
@@ -22,9 +22,9 @@ module VagrantPlugins
|
|
22
22
|
#
|
23
23
|
def call(env)
|
24
24
|
@app.call(env)
|
25
|
-
unless env[:
|
25
|
+
unless env[:machine].config.sh.after_share_folders.nil?
|
26
26
|
@machine.action(:ssh_run,
|
27
|
-
ssh_run_command: env[:
|
27
|
+
ssh_run_command: env[:machine].config.sh.after_share_folders,
|
28
28
|
ssh_opts: {extra_args: []})
|
29
29
|
end
|
30
30
|
end
|
data/spec/action_spec.rb
CHANGED
@@ -6,8 +6,9 @@ describe VagrantPlugins::ShellCommander::Action do
|
|
6
6
|
let(:env) {double(:[] => machine)}
|
7
7
|
let(:cmd) {'cmd'}
|
8
8
|
let(:sh) {double(after_share_folders: cmd)}
|
9
|
-
let(:
|
10
|
-
let(:
|
9
|
+
let(:config) {double(sh: sh)}
|
10
|
+
let(:machine_env) {double(config: config)}
|
11
|
+
let(:action_env) {{machine: machine_env}}
|
11
12
|
let(:subject) {described_class.new(app, env)}
|
12
13
|
|
13
14
|
describe "#call" do
|
@@ -28,8 +29,9 @@ describe VagrantPlugins::ShellCommander::Action do
|
|
28
29
|
|
29
30
|
it "should not call SSHRun action if after_boot option is nil" do
|
30
31
|
sh = double(after_share_folders: nil)
|
31
|
-
|
32
|
-
|
32
|
+
config = double(sh: sh)
|
33
|
+
machine_env = double(config: config)
|
34
|
+
action_env = {machine: machine_env}
|
33
35
|
|
34
36
|
expect(machine).not_to receive(:action)
|
35
37
|
|
data/spec/plugin_spec.rb
CHANGED
@@ -6,9 +6,8 @@ describe VagrantPlugins::ShellCommander::Plugin do
|
|
6
6
|
end
|
7
7
|
|
8
8
|
it "should define a command of type Command" do
|
9
|
-
default_command = described_class.
|
10
|
-
|
11
|
-
expect(default_command).to be(VagrantPlugins::ShellCommander::Command)
|
9
|
+
default_command = described_class.components.commands[:sh]
|
10
|
+
expect(default_command[1]).to eql(primary: true)
|
12
11
|
end
|
13
12
|
|
14
13
|
it "should define a config of type Config" do
|
metadata
CHANGED
@@ -1,126 +1,111 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: vagrant-shell-commander
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
5
|
-
prerelease:
|
4
|
+
version: 0.3.1
|
6
5
|
platform: ruby
|
7
6
|
authors:
|
8
7
|
- Federico Gimenez Nieto
|
9
8
|
autorequire:
|
10
9
|
bindir: bin
|
11
10
|
cert_chain: []
|
12
|
-
date: 2014-
|
11
|
+
date: 2014-03-17 00:00:00.000000000 Z
|
13
12
|
dependencies:
|
14
13
|
- !ruby/object:Gem::Dependency
|
15
14
|
name: bundler
|
16
15
|
requirement: !ruby/object:Gem::Requirement
|
17
|
-
none: false
|
18
16
|
requirements:
|
19
|
-
- - ~>
|
17
|
+
- - "~>"
|
20
18
|
- !ruby/object:Gem::Version
|
21
19
|
version: '1.3'
|
22
20
|
type: :development
|
23
21
|
prerelease: false
|
24
22
|
version_requirements: !ruby/object:Gem::Requirement
|
25
|
-
none: false
|
26
23
|
requirements:
|
27
|
-
- - ~>
|
24
|
+
- - "~>"
|
28
25
|
- !ruby/object:Gem::Version
|
29
26
|
version: '1.3'
|
30
27
|
- !ruby/object:Gem::Dependency
|
31
28
|
name: rake
|
32
29
|
requirement: !ruby/object:Gem::Requirement
|
33
|
-
none: false
|
34
30
|
requirements:
|
35
|
-
- -
|
31
|
+
- - ">="
|
36
32
|
- !ruby/object:Gem::Version
|
37
33
|
version: '0'
|
38
34
|
type: :development
|
39
35
|
prerelease: false
|
40
36
|
version_requirements: !ruby/object:Gem::Requirement
|
41
|
-
none: false
|
42
37
|
requirements:
|
43
|
-
- -
|
38
|
+
- - ">="
|
44
39
|
- !ruby/object:Gem::Version
|
45
40
|
version: '0'
|
46
41
|
- !ruby/object:Gem::Dependency
|
47
42
|
name: rspec
|
48
43
|
requirement: !ruby/object:Gem::Requirement
|
49
|
-
none: false
|
50
44
|
requirements:
|
51
|
-
- -
|
45
|
+
- - ">="
|
52
46
|
- !ruby/object:Gem::Version
|
53
47
|
version: '0'
|
54
48
|
type: :development
|
55
49
|
prerelease: false
|
56
50
|
version_requirements: !ruby/object:Gem::Requirement
|
57
|
-
none: false
|
58
51
|
requirements:
|
59
|
-
- -
|
52
|
+
- - ">="
|
60
53
|
- !ruby/object:Gem::Version
|
61
54
|
version: '0'
|
62
55
|
- !ruby/object:Gem::Dependency
|
63
56
|
name: reek
|
64
57
|
requirement: !ruby/object:Gem::Requirement
|
65
|
-
none: false
|
66
58
|
requirements:
|
67
|
-
- -
|
59
|
+
- - ">="
|
68
60
|
- !ruby/object:Gem::Version
|
69
61
|
version: '0'
|
70
62
|
type: :development
|
71
63
|
prerelease: false
|
72
64
|
version_requirements: !ruby/object:Gem::Requirement
|
73
|
-
none: false
|
74
65
|
requirements:
|
75
|
-
- -
|
66
|
+
- - ">="
|
76
67
|
- !ruby/object:Gem::Version
|
77
68
|
version: '0'
|
78
69
|
- !ruby/object:Gem::Dependency
|
79
70
|
name: cane
|
80
71
|
requirement: !ruby/object:Gem::Requirement
|
81
|
-
none: false
|
82
72
|
requirements:
|
83
|
-
- -
|
73
|
+
- - ">="
|
84
74
|
- !ruby/object:Gem::Version
|
85
75
|
version: '0'
|
86
76
|
type: :development
|
87
77
|
prerelease: false
|
88
78
|
version_requirements: !ruby/object:Gem::Requirement
|
89
|
-
none: false
|
90
79
|
requirements:
|
91
|
-
- -
|
80
|
+
- - ">="
|
92
81
|
- !ruby/object:Gem::Version
|
93
82
|
version: '0'
|
94
83
|
- !ruby/object:Gem::Dependency
|
95
84
|
name: yard
|
96
85
|
requirement: !ruby/object:Gem::Requirement
|
97
|
-
none: false
|
98
86
|
requirements:
|
99
|
-
- -
|
87
|
+
- - ">="
|
100
88
|
- !ruby/object:Gem::Version
|
101
89
|
version: '0'
|
102
90
|
type: :development
|
103
91
|
prerelease: false
|
104
92
|
version_requirements: !ruby/object:Gem::Requirement
|
105
|
-
none: false
|
106
93
|
requirements:
|
107
|
-
- -
|
94
|
+
- - ">="
|
108
95
|
- !ruby/object:Gem::Version
|
109
96
|
version: '0'
|
110
97
|
- !ruby/object:Gem::Dependency
|
111
98
|
name: simplecov
|
112
99
|
requirement: !ruby/object:Gem::Requirement
|
113
|
-
none: false
|
114
100
|
requirements:
|
115
|
-
- -
|
101
|
+
- - ">="
|
116
102
|
- !ruby/object:Gem::Version
|
117
103
|
version: '0'
|
118
104
|
type: :development
|
119
105
|
prerelease: false
|
120
106
|
version_requirements: !ruby/object:Gem::Requirement
|
121
|
-
none: false
|
122
107
|
requirements:
|
123
|
-
- -
|
108
|
+
- - ">="
|
124
109
|
- !ruby/object:Gem::Version
|
125
110
|
version: '0'
|
126
111
|
description: Vagrant plugin for executing shell commands on guests machines and hooking
|
@@ -131,9 +116,9 @@ executables: []
|
|
131
116
|
extensions: []
|
132
117
|
extra_rdoc_files: []
|
133
118
|
files:
|
134
|
-
- .gitignore
|
135
|
-
- .rspec
|
136
|
-
- .travis.yml
|
119
|
+
- ".gitignore"
|
120
|
+
- ".rspec"
|
121
|
+
- ".travis.yml"
|
137
122
|
- Gemfile
|
138
123
|
- Gemfile.lock
|
139
124
|
- LICENSE.txt
|
@@ -160,33 +145,26 @@ files:
|
|
160
145
|
homepage: https://github.com/fgimenez/vagrant-shell-commander
|
161
146
|
licenses:
|
162
147
|
- MIT
|
148
|
+
metadata: {}
|
163
149
|
post_install_message:
|
164
150
|
rdoc_options: []
|
165
151
|
require_paths:
|
166
152
|
- lib
|
167
153
|
required_ruby_version: !ruby/object:Gem::Requirement
|
168
|
-
none: false
|
169
154
|
requirements:
|
170
|
-
- -
|
155
|
+
- - ">="
|
171
156
|
- !ruby/object:Gem::Version
|
172
157
|
version: '0'
|
173
|
-
segments:
|
174
|
-
- 0
|
175
|
-
hash: -2972945200673106497
|
176
158
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
177
|
-
none: false
|
178
159
|
requirements:
|
179
|
-
- -
|
160
|
+
- - ">="
|
180
161
|
- !ruby/object:Gem::Version
|
181
162
|
version: '0'
|
182
|
-
segments:
|
183
|
-
- 0
|
184
|
-
hash: -2972945200673106497
|
185
163
|
requirements: []
|
186
164
|
rubyforge_project:
|
187
|
-
rubygems_version:
|
165
|
+
rubygems_version: 2.2.2
|
188
166
|
signing_key:
|
189
|
-
specification_version:
|
167
|
+
specification_version: 4
|
190
168
|
summary: Some variations to shell command execution on guest(s)
|
191
169
|
test_files:
|
192
170
|
- spec/action_spec.rb
|