Sha256: f8374626db1161878b449df045d39a2358e0e3812674882deaa72941d6f84574

Contents?: true

Size: 1.04 KB

Versions: 2

Compression:

Stored size: 1.04 KB

Contents

#!/usr/bin/env ruby

require 'rubygems'
require 'commander'
require 'yaml'

require 'start_x/config'
require 'start_x/project'
require 'start_x/version'


module StartX
  class Runner
    include Commander::Methods
    # include whatever modules you need

    def run
      program :name, 'starters'
      program :version, StartX::VERSION
      program :description, 'Easily kickoff projects from git'
      default_command :project

      command :config do |c|
        c.syntax = 'start config [options]'
        c.summary = ''
        c.description = ''
        c.example 'description', 'command example'
        c.option '--some-switch', 'Some switch that does something'
        c.action do |args, options|
          StartX::Config.new
        end
      end

      command :project do |c|
        c.syntax = 'start project [options]'
        c.summary = ''
        c.description = ''
        c.example 'description', 'command example'
        c.action do |args, options|
          StartX::Project.new
        end
      end

      run!
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
start-x-0.0.3 lib/start_x.rb
start-x-0.0.2 lib/start_x.rb