Class: SshyGuy::Screens::FolderScreen

Inherits:
SshyGuy::Screen show all
Defined in:
lib/sshyguy/screens/folder_screen.rb

Instance Attribute Summary

Attributes inherited from SshyGuy::Screen

#options, #prompt

Instance Method Summary collapse

Methods inherited from SshyGuy::Screen

#initialize, show

Constructor Details

This class inherits a constructor from SshyGuy::Screen

Instance Method Details

#showObject



6
7
8
9
10
11
12
13
14
15
# File 'lib/sshyguy/screens/folder_screen.rb', line 6

def show
  selected = prompt.select('Select a folder') do |select|
    Server.folders.each do |folder|
      select.choice(folder)
    end
    select.choice('All servers', '__ALL')
  end
  SshyGuy.params[:folder] = selected
  MainScreen.show(options)
end