diff --git a/lib/rtoolsHCK.rb b/lib/rtoolsHCK.rb index 07f62e3..3e60e75 100755 --- a/lib/rtoolsHCK.rb +++ b/lib/rtoolsHCK.rb @@ -1125,6 +1125,22 @@ def run_on_machine(machine, cmd) end end + # == Description + # + # Run command on a studio, (powershell). + # + # == Params: + # + # +command+:: The command to run as a string + def run_on_studio(command) + handle_action_exceptions(__method__) do + ret = run(command) + return (@json ? { 'result' => 'Success' } : true) if ret.empty? + + @json ? { 'result' => 'Success', 'content' => ret } : true + end + end + # == Description # # Upload directory to temp directory of the machine.