class HashiCorp::VagrantVMwareDesktop::Action::Running
This can be used with “Call” built-in to check if the machine is running.
Public Class Methods
new(app, env)
click to toggle source
# File lib/vagrant-vmware-desktop/action/running.rb, line 9 def initialize(app, env) @app = app end
Public Instance Methods
call(env)
click to toggle source
# File lib/vagrant-vmware-desktop/action/running.rb, line 13 def call(env) env[:result] = env[:machine].state.id == :running @app.call(env) end