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, UsageException

Constant Summary collapse

VERSION =
'0.1.0'

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.root_commandObject (readonly)

Returns the value of attribute root_command.



29
30
31
# File 'lib/forematter.rb', line 29

def root_command
  @root_command
end

Class Method Details

.add_command(cmd) ⇒ Object



39
40
41
# File 'lib/forematter.rb', line 39

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

.run(args) ⇒ Object

attr_accessor :verbose



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

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