Class: Metaverse::Cli
- Inherits:
-
Thor
- Object
- Thor
- Metaverse::Cli
- Defined in:
- lib/metaverse/cli.rb
Instance Method Summary collapse
- #branches ⇒ Object
- #check(command) ⇒ Object
- #checkout(name) ⇒ Object
- #develop ⇒ Object
- #feature(command, name) ⇒ Object
- #init ⇒ Object
- #snapshot(command, name) ⇒ Object
- #status ⇒ Object
- #update(remote = nil) ⇒ Object
Instance Method Details
#branches ⇒ Object
12 13 14 15 |
# File 'lib/metaverse/cli.rb', line 12 def branches init .branches end |
#check(command) ⇒ Object
63 64 65 66 67 68 69 |
# File 'lib/metaverse/cli.rb', line 63 def check command init case command when 'consistency' then .checkConsistency when 'dirtiness' then .checkDirtiness end end |
#checkout(name) ⇒ Object
57 58 59 60 |
# File 'lib/metaverse/cli.rb', line 57 def checkout name init .checkout name end |
#develop ⇒ Object
51 52 53 54 |
# File 'lib/metaverse/cli.rb', line 51 def develop init .checkout 'develop' end |
#feature(command, name) ⇒ Object
28 29 30 31 32 33 34 35 |
# File 'lib/metaverse/cli.rb', line 28 def feature command, name init case command when 'new' then .createFeature name when 'load' then .loadFeature name when 'deploy' then .deploy "feature/#{name}" end end |
#init ⇒ Object
7 8 9 |
# File 'lib/metaverse/cli.rb', line 7 def init = Base.new Dir.pwd end |
#snapshot(command, name) ⇒ Object
18 19 20 21 22 23 24 25 |
# File 'lib/metaverse/cli.rb', line 18 def snapshot command, name init case command when 'new' then .createSnapshot name when 'load' then .loadSnapshot name when 'deploy' then .deploy "tags/#{name}" end end |
#status ⇒ Object
38 39 40 41 42 |
# File 'lib/metaverse/cli.rb', line 38 def status init puts "System is at #{@meta.systemState.first}" .status end |
#update(remote = nil) ⇒ Object
45 46 47 48 |
# File 'lib/metaverse/cli.rb', line 45 def update remote = nil init .update remote end |