Class: CommandLine
- Inherits:
-
Object
- Object
- CommandLine
- Defined in:
- lib/command_line.rb
Constant Summary collapse
- START_MARKER =
"### BEGIN whenever generated crontab ###"
- END_MARKER =
"### END whenever generated crontab ###"
Instance Attribute Summary collapse
-
#options ⇒ Object
readonly
Returns the value of attribute options.
Instance Method Summary collapse
- #end_marker ⇒ Object
-
#initialize(options = {}) ⇒ CommandLine
constructor
A new instance of CommandLine.
- #start_marker ⇒ Object
- #update! ⇒ Object
- #write! ⇒ Object
Constructor Details
#initialize(options = {}) ⇒ CommandLine
Returns a new instance of CommandLine.
15 16 17 18 |
# File 'lib/command_line.rb', line 15 def initialize( = {}) @options = @marker = [:marker] || "whenever generated crontab" end |
Instance Attribute Details
#options ⇒ Object (readonly)
Returns the value of attribute options.
5 6 7 |
# File 'lib/command_line.rb', line 5 def @options end |
Instance Method Details
#end_marker ⇒ Object
11 12 13 |
# File 'lib/command_line.rb', line 11 def end_marker "### END #{@marker} ###" end |
#start_marker ⇒ Object
7 8 9 |
# File 'lib/command_line.rb', line 7 def start_marker "### BEGIN #{@marker} ###" end |