Method: Bookshelf::Cli#initialize

Defined in:
lib/bookshelf/cli.rb

#initialize(args = [], options = {}, config = {}) ⇒ Cli

Returns a new instance of Cli.



11
12
13
14
15
16
17
# File 'lib/bookshelf/cli.rb', line 11

def initialize(args = [], options = {}, config = {})
  if (config[:current_task] || config[:current_command]).name == "new" && args.empty?
    raise Error, "The e-Book path is required. For details run: bookshelf help new"
  end

  super
end