Class: Posto::Arguments

Inherits:
Object
  • Object
show all
Defined in:
lib/posto/arguments.rb

Instance Method Summary collapse

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

#commandObject



11
12
13
# File 'lib/posto/arguments.rb', line 11

def command
  @args[0] || "list"
end

#filenameObject



15
16
17
# File 'lib/posto/arguments.rb', line 15

def filename
  "posto.md"
end

#paramsObject



7
8
9
# File 'lib/posto/arguments.rb', line 7

def params
  @args[1..-1] || []
end