Sha256: 20921e73a79701d5b8e0d6c5dd02290be6c0c70305ad58bd04f4d0623dce231e

Contents?: true

Size: 1.08 KB

Versions: 57

Compression:

Stored size: 1.08 KB

Contents

#!/usr/bin/env ruby
require_relative '../lib/mobile_workflow/cli'

# Byebug for dev
begin
  require 'byebug'
rescue LoadError
end

if ARGV.empty?
  puts "USAGE: mwf <platform> <command> [options]"
  puts "Example: mwf rails create:app_server --help"
  puts "Example: mwf rails destroy:app_server --help"
  exit 0
elsif ['-v', '--version'].include? ARGV[0]
  puts MobileWorkflow::VERSION
  exit 0
elsif 'rails' == ARGV[0] && 'create:app_server' == ARGV[1]
  ARGV.shift
  ARGV.shift
  
  templates_root = File.expand_path(File.join("..", "lib", "generators", "mobile_workflow", "install", "templates"), File.dirname(__FILE__))
  MobileWorkflow::Cli::AppServerGenerator.source_root templates_root
  MobileWorkflow::Cli::AppServerGenerator.source_paths << Rails::Generators::AppGenerator.source_root << templates_root
  MobileWorkflow::Cli::AppServerGenerator.start
elsif 'rails' == ARGV[0] && 'destroy:app_server' == ARGV[1]
  ARGV.shift
  ARGV.shift
  
  ARGV.unshift(MobileWorkflow::Cli::AppServerCleaner.default_task) unless ARGV[0] == '--help'
  MobileWorkflow::Cli::AppServerCleaner.start(ARGV)
end


Version data entries

57 entries across 57 versions & 1 rubygems

Version Path
mobile_workflow-0.10.2 bin/mwf
mobile_workflow-0.10.1 bin/mwf
mobile_workflow-0.10.0 bin/mwf
mobile_workflow-0.9.0 bin/mwf
mobile_workflow-0.8.9 bin/mwf
mobile_workflow-0.7.9 bin/mwf
mobile_workflow-0.7.8 bin/mwf
mobile_workflow-0.7.7 bin/mwf
mobile_workflow-0.7.6 bin/mwf
mobile_workflow-0.7.5 bin/mwf
mobile_workflow-0.7.4 bin/mwf
mobile_workflow-0.7.3 bin/mwf
mobile_workflow-0.7.2 bin/mwf
mobile_workflow-0.7.1 bin/mwf
mobile_workflow-0.7.0 bin/mwf
mobile_workflow-0.6.31 bin/mwf
mobile_workflow-0.6.30 bin/mwf
mobile_workflow-0.6.29 bin/mwf
mobile_workflow-0.6.28 bin/mwf
mobile_workflow-0.6.27 bin/mwf