Class: M2H::OptParser

Inherits:
OptionParser
  • Object
show all
Defined in:
lib/m2h/optparser.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeOptParser

Returns a new instance of OptParser.



7
8
9
10
11
12
13
14
15
16
17
18
19
# File 'lib/m2h/optparser.rb', line 7

def initialize
  @help = <<-HELP
  Usage  : m2h <markdonw_file1> <markdonw_file2> ...
  Options:
-s, --serif   : font-family -> serif
-d, --header  : with header
-c, --cover   : with cover page
-t, --toc     : use tocify.js
-h, --help    : show this messages
-v, --version : show version infomation
  HELP
  super
end

Instance Attribute Details

#helpObject (readonly)

Returns the value of attribute help.



5
6
7
# File 'lib/m2h/optparser.rb', line 5

def help
  @help
end