Skip to content

Instantly share code, notes, and snippets.

@Tyderion
Last active December 16, 2015 10:29
Show Gist options
  • Save Tyderion/5420682 to your computer and use it in GitHub Desktop.
Save Tyderion/5420682 to your computer and use it in GitHub Desktop.
Applescript to open the document which is currently active in XCode 4.2 in sublimetext 3
tell application "Xcode"
activate
--display dialog "window1: " & (get name of window 0)
set CurrentActiveDocument to document 1 whose name ends with (word -1 of (get name of window 1))
set WhatYouWant to path of CurrentActiveDocument
end tell
tell application "Sublime Text 3"
activate (open WhatYouWant)
end tell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment