Method: Aspera::OpenApplication.uri_graphical

Defined in:
lib/aspera/open_application.rb

.uri_graphical(uri) ⇒ Object

command must be non blocking



27
28
29
30
31
32
33
34
35
# File 'lib/aspera/open_application.rb', line 27

def uri_graphical(uri)
  case Environment.os
  when Environment::OS_X       then return system('open', uri.to_s)
  when Environment::OS_WINDOWS then return system('start', 'explorer', %Q{"#{uri}"})
  when Environment::OS_LINUX   then return system('xdg-open', uri.to_s)
  else
    raise "no graphical open method for #{Environment.os}"
  end
end