Module: Cardio::Commands::Accessors

Included in:
Cardio::Commands
Defined in:
lib/cardio/commands.rb

Overview

class methods for commands (basically simulates cattr_reader, which isn’t available here)

Instance Method Summary collapse

Instance Method Details

#aliasesObject



11
12
13
14
15
16
17
18
19
20
21
22
23
# File 'lib/cardio/commands.rb', line 11

def aliases
  @aliases ||= {
    "rs" => "rspec",
    "jm" => "jasmine",
    "g"  => "generate",
    "d"  => "destroy",
    "c"  => "console",
    "db" => "dbconsole",
    "r"  => "runner",
    "v"  => "version",
    "h"  => "help"
  }
end

#commandsObject



25
26
27
28
29
30
31
32
# File 'lib/cardio/commands.rb', line 25

def commands
  @commands ||= {
    rails:  %w[generate destroy plugin benchmarker profiler
               console dbconsole application runner],
    rake:   %w[seed reseed load update],
    custom: %w[new rspec jasmine version help]
  }
end