Class: Gzr::Commands::Dashboard

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

Defined Under Namespace

Classes: Cat, Import, ImportLookml, Mv, Rm, SyncLookml

Instance Method Summary collapse

Methods inherited from SubCommandBase

banner, subcommand_prefix

Instance Method Details

#cat(dashboard_id) ⇒ Object



59
60
61
62
63
64
65
66
# File 'lib/gzr/commands/dashboard.rb', line 59

def cat(dashboard_id)
  if options[:help]
    invoke :help, ['cat']
  else
    require_relative 'dashboard/cat'
    Gzr::Commands::Dashboard::Cat.new(dashboard_id, options).execute
  end
end

#import(file, dest_folder_id) ⇒ Object



75
76
77
78
79
80
81
82
# File 'lib/gzr/commands/dashboard.rb', line 75

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

#import_lookml(dashboard_id, target_folder_id) ⇒ Object



109
110
111
112
113
114
115
116
# File 'lib/gzr/commands/dashboard.rb', line 109

def import_lookml(dashboard_id, target_folder_id)
  if options[:help]
    invoke :help, ['import_lookml']
  else
    require_relative 'dashboard/import_lookml'
    Gzr::Commands::Dashboard::ImportLookml.new(dashboard_id, target_folder_id, options).execute
  end
end

#mv(dashboard_id, target_folder_id) ⇒ Object



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

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

#rm(id) ⇒ Object



91
92
93
94
95
96
97
98
# File 'lib/gzr/commands/dashboard.rb', line 91

def rm(id)
  if options[:help]
    invoke :help, ['rm']
  else
    require_relative 'dashboard/rm'
    Gzr::Commands::Dashboard::Rm.new(id, options).execute
  end
end

#sync_lookml(dashboard_id) ⇒ Object



121
122
123
124
125
126
127
128
# File 'lib/gzr/commands/dashboard.rb', line 121

def sync_lookml(dashboard_id)
  if options[:help]
    invoke :help, ['sync_lookml']
  else
    require_relative 'dashboard/sync_lookml'
    Gzr::Commands::Dashboard::SyncLookml.new(dashboard_id, options).execute
  end
end