Sha256: 00e242a09bda4b4b1549286173498a4998bbcf23773962d8098b54aa23c9dd80

Contents?: true

Size: 652 Bytes

Versions: 4

Compression:

Stored size: 652 Bytes

Contents

require 'thor'

module Simplexframe
	class CLI < Thor	
		include Thor::Actions

		argument :app_name, required: false

		def self.source_root
			File.join File.dirname(__FILE__), 'generators'
		end

		desc 'new', 'create a simplexframe project'
		def new
			if app_name
				directory 'simplexframe', app_name
			else
				say 'no app name'
			end 
		end

		desc 'go ', 'run test case with rspec'
		def go
			ARGV.shift
			puts "rspec #{ARGV.join('')}" if $debug
			run "rspec #{ARGV.join('')}"
		end

		desc 'c ', 'open simplexframe console'
		def c
			run 'bin/console'
		end
		
	end
CLI.start

end #Simplexframe

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
simplexframe-0.0.04 lib/simplexframe/cli.rb
simplexframe-0.0.03 lib/simplexframe/cli.rb
simplexframe-0.0.02 lib/simplexframe/cli.rb
simplexframe-0.0.01 lib/simplexframe/cli.rb