bin/wara
#!/usr/bin/env ruby
require "wara/version"
require "wara"
require "thor"
module Wara
#= Wara CLI
class CLI < Thor
default_task :create
option :model, :type => :string, :aliases => '-m',:required => true, :desc => 'Path to model'
option :out, :type => :string, :aliases => '-o', :desc => 'Output directory'
option :swift, :type => :boolean, :desc => 'Generate Swift'
desc "create", "create scapegoat objects"
def create
Wara::Core.new.create(options[:model], options[:out], options[:swift] ? Lang::Swift : Lang::ObjC)
puts 'Generate'
end
desc "version", "version"
def version
p Wara::VERSION
end
end
end
Wara::CLI.start(ARGV)