Module: Forematter

Defined in:
lib/forematter.rb,
lib/forematter/version.rb,
lib/forematter/frontmatter.rb,
lib/forematter/file_wrapper.rb,
lib/forematter/command_runner.rb

Defined Under Namespace

Modules: Commands Classes: CommandRunner, FileWrapper, Frontmatter, UnexpectedValue, UsageException

Constant Summary collapse

VERSION =
'0.1.1'

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.root_commandObject (readonly)

Returns the value of attribute root_command.



32
33
34
# File 'lib/forematter.rb', line 32

def root_command
  @root_command
end

Class Method Details

.add_command(cmd) ⇒ Object



42
43
44
# File 'lib/forematter.rb', line 42

def add_command(cmd)
  root_command.add_command(cmd)
end

.run(args) ⇒ Object

attr_accessor :verbose



35
36
37
38
39
40
# File 'lib/forematter.rb', line 35

def run(args)
  # Remove the signal trap we set in the bin file.
  Signal.trap('INT', 'DEFAULT')
  setup
  root_command.run(args)
end