Class: Stg::CLI
Instance Attribute Summary
Attributes included from DiffCalc
Class Method Summary collapse
Methods included from Actions
branch, checkout, commit, diff, log, p_initialize, reset, stage
Methods included from DiffCalc
#build_sequences, #compute_diff, #differencing, #initialize, #print_diff, #print_line
Methods included from Help
Class Method Details
.start ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
# File 'lib/stg.rb', line 9 def self.start command = ARGV.shift case command when 'init' p_initialize when 'commit' commit when 'diff' diff when 'test' test when 'stage' stage when 'check_router' check_router when 'reset' reset when 'log' log when 'checkout' checkout when 'branch' branch when 'help' puts print_usage exit 1 when nil puts print_usage exit 1 else puts "Unknown command: #{command}" exit 1 end end |