Method: HookApp#open_gui
- Defined in:
- lib/hook/hookapp.rb
#open_gui(url) ⇒ Object
Open the Hook GUI for browsing/performing actions on a file or url
317 318 319 320 321 322 323 324 325 326 327 328 329 330 |
# File 'lib/hook/hookapp.rb', line 317 def open_gui(url) result = `osascript <<'APPLESCRIPT' tell application "#{HOOK_APP}" set _mark to make bookmark with data "#{url.valid_hook}" if _mark is missing value return "Failed to create bookmark for #{url}" else invoke on _mark return "" end if end tell APPLESCRIPT`.strip raise result unless result.empty? end |