# File lib/hammer_cli_foreman_tasks/helper.rb, line 12 def load_task(id) HammerCLIForeman.foreman_resource!(:foreman_tasks).call(:show, :id => id) end
render the progress of the task using polling to the task API
# File lib/hammer_cli_foreman_tasks/helper.rb, line 5 def task_progress(task_or_id) task_id = task_or_id.is_a?(Hash) ? task_or_id['id'] : task_or_id TaskProgress.new(task_id) { |id| load_task(id) }.tap do |task_progress| task_progress.render end end
Generated with the Darkfish Rdoc Generator 2.