class Shard::CLI::Commands

Public Instance Methods

config() click to toggle source
# File lib/shard/cli/commands.rb, line 63
def config
  Shard::CLI::Config.run
end
exec(shard_line) click to toggle source
# File lib/shard/cli/commands.rb, line 27
def exec(shard_line)
  Shard::Loader.load shard_line
end
fetch(shard_line) click to toggle source
# File lib/shard/cli/commands.rb, line 39
def fetch(shard_line)
  Shard::Saver.save shard_line, verbose: true
end
fork(shard_line) click to toggle source
# File lib/shard/cli/commands.rb, line 95
def fork(shard_line)
    Shard::CLI::Fork.run shard_line
end
list(username) click to toggle source
# File lib/shard/cli/commands.rb, line 15
def list(username)
  Shard::CLI::List.run(username)
end
test(shard_line) click to toggle source
# File lib/shard/cli/commands.rb, line 51
def test(shard_line)
  Shard::Loader.test shard_line
end
view(shard_line) click to toggle source
# File lib/shard/cli/commands.rb, line 75
def view(shard_line)
  if line = Shard::Ref.parse(shard_line)
    lister = Shard::Lister.new(line.user)
    shard  = lister.shards[line.name]
    url    = shard.url

    `open #{ url }`
  else
    puts "'#{ shard_line }' is not a valid shard reference."
  end
end