Class: Scene7ize::CLI

Inherits:
Thor
  • Object
show all
Defined in:
lib/scene7ize/cli.rb

Overview

Facade for Scene7ize command line interface managed by [Thor](github.com/wycats/thor). This is the main interface to Scene7ize that is called by the Scene7ize binary bin/scene7ize. Do not put any logic in here, create a class and delegate instead.

Instance Method Summary collapse

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(meth, *args) ⇒ Object (private)



50
51
52
# File 'lib/scene7ize/cli.rb', line 50

def method_missing(meth, *args)
  help
end

Instance Method Details

#parseObject



30
31
32
33
34
# File 'lib/scene7ize/cli.rb', line 30

def parse

  Scene7ize.parse_file(options[:url_prefix], options[:input_file], options[:output_file])

end

#versionObject

Shows the current version of Scene7ize.

See Also:



44
45
46
# File 'lib/scene7ize/cli.rb', line 44

def version
  puts "Scene7ize version #{ ::Scene7ize::VERSION }"
end