Class: Posto::Arguments
- Inherits:
-
Object
- Object
- Posto::Arguments
- Defined in:
- lib/posto/arguments.rb
Instance Method Summary collapse
- #command ⇒ Object
- #filename ⇒ Object
-
#initialize(args) ⇒ Arguments
constructor
A new instance of Arguments.
- #params ⇒ Object
Constructor Details
#initialize(args) ⇒ Arguments
Returns a new instance of Arguments.
3 4 5 |
# File 'lib/posto/arguments.rb', line 3 def initialize(args) @args = args end |
Instance Method Details
#command ⇒ Object
11 12 13 |
# File 'lib/posto/arguments.rb', line 11 def command @args[0] || "list" end |
#filename ⇒ Object
15 16 17 |
# File 'lib/posto/arguments.rb', line 15 def filename "posto.md" end |
#params ⇒ Object
7 8 9 |
# File 'lib/posto/arguments.rb', line 7 def params @args[1..-1] || [] end |