Sha256: 78b01f4b2b3a039cc549ffc80fb42942bb2e2dd6768f466a016bfc31ddcc6c34
Contents?: true
Size: 1011 Bytes
Versions: 4
Compression:
Stored size: 1011 Bytes
Contents
#!/usr/bin/env ruby require 'pry' Pry.config.prompt = proc { "robi> " } command_set = Pry::CommandSet.new do block_command "start", "Start all robots working" do if defined?(Artoo::MainRobot) output.puts "Starting main robot..." Artoo::MainRobot.work! unless Artoo::MainRobot.is_running? else output.puts "Starting robots..." end Celluloid::Actor[:master].start_work end block_command "pause", "Pause all robots" do output.puts "Pausing robots..." Celluloid::Actor[:master].pause_work end block_command "continue", "Continue all robots" do output.puts "Continuing robots..." Celluloid::Actor[:master].continue_work end block_command "stop", "Stop all robots" do output.puts "Not yet implemented..." Celluloid::Actor[:master].stop_work end block_command "list", "List all robots" do output.puts Celluloid::Actor[:master].robots end end Pry::Commands.import command_set ENV["ARTOO_CLI"] = 'true' require ARGV[0] Pry.start
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
artoo-0.5.0 | bin/robi |
artoo-0.4.1 | bin/robi |
artoo-0.4.0 | bin/robi |
artoo-0.3.0 | bin/robi |