Class: Gzr::Commands::Look

Inherits:
SubCommandBase show all
Defined in:
lib/gzr/commands/look.rb,
lib/gzr/commands/look/mv.rb,
lib/gzr/commands/look/rm.rb,
lib/gzr/commands/look/cat.rb,
lib/gzr/commands/look/import.rb

Defined Under Namespace

Classes: Cat, Import, Mv, Rm

Instance Method Summary collapse

Methods inherited from SubCommandBase

banner, subcommand_prefix

Instance Method Details

#cat(look_id) ⇒ Object



89
90
91
92
93
94
95
96
# File 'lib/gzr/commands/look.rb', line 89

def cat(look_id)
  if options[:help]
    invoke :help, ['cat']
  else
    require_relative 'look/cat'
    Gzr::Commands::Look::Cat.new(look_id, options).execute
  end
end

#import(file, dest_folder_id) ⇒ Object



69
70
71
72
73
74
75
76
# File 'lib/gzr/commands/look.rb', line 69

def import(file,dest_folder_id)
  if options[:help]
    invoke :help, ['import']
  else
    require_relative 'look/import'
    Gzr::Commands::Look::Import.new(file, dest_folder_id, options).execute
  end
end

#mv(look_id, target_folder_id) ⇒ Object



37
38
39
40
41
42
43
44
# File 'lib/gzr/commands/look.rb', line 37

def mv(look_id, target_folder_id)
  if options[:help]
    invoke :help, ['mv']
  else
    require_relative 'look/mv'
    Gzr::Commands::Look::Mv.new(look_id, target_folder_id, options).execute
  end
end

#rm(look_id) ⇒ Object



53
54
55
56
57
58
59
60
# File 'lib/gzr/commands/look.rb', line 53

def rm(look_id)
  if options[:help]
    invoke :help, ['rm']
  else
    require_relative 'look/rm'
    Gzr::Commands::Look::Rm.new(look_id, options).execute
  end
end