Class: Vagrant::Notify::Action::InstallCommand
- Inherits:
-
Object
- Object
- Vagrant::Notify::Action::InstallCommand
- Defined in:
- lib/vagrant-notify/action/install_command.rb
Instance Method Summary collapse
- #call(env) ⇒ Object
-
#initialize(app, env) ⇒ InstallCommand
constructor
A new instance of InstallCommand.
Constructor Details
#initialize(app, env) ⇒ InstallCommand
Returns a new instance of InstallCommand.
5 6 7 |
# File 'lib/vagrant-notify/action/install_command.rb', line 5 def initialize(app, env) @app = app end |
Instance Method Details
#call(env) ⇒ Object
9 10 11 12 13 14 15 16 17 |
# File 'lib/vagrant-notify/action/install_command.rb', line 9 def call(env) return if env[:machine].config.notify.enable == false path = compile_command(env, 'notify-send.erb') install_command_on_guest(env, path) check_if_ruby_on_guest(env) @app.call env end |