Class: Rea::Command::Search

Inherits:
Object
  • Object
show all
Includes:
Utils
Defined in:
lib/rea/command/search.rb

Overview

Search publications on the online libraries

SYNOPSIS

#{command_name} [options] ARG

OPTIONS #summarized_options

Constant Summary

Constants included from Utils

Utils::DEFAULT_INFO

Instance Method Summary collapse

Methods included from Utils

#pretty

Instance Method Details

#execute(args) ⇒ Object

Run the command

Raises:

  • (Quickl::Help)


44
45
46
47
48
# File 'lib/rea/command/search.rb', line 44

def execute(args)
  raise Quickl::Help if args.size > 1
  @query[@mainarg] = args.first if args.size == 1
  @provider.search(@query)
end

#run(*args) ⇒ Object



39
40
41
# File 'lib/rea/command/search.rb', line 39

def run(*args)
  puts pretty(super, @keep)
end