Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@davebrny
Last active February 26, 2018 18:30
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save davebrny/28bae35c10b67df67b993e7c30cfdc71 to your computer and use it in GitHub Desktop.
Save davebrny/28bae35c10b67df67b993e7c30cfdc71 to your computer and use it in GitHub Desktop.
(autohotkey) - open a file in sublime text (for the portable version that lacks the context menu option)
#ifWinActive ahk_class CabinetWClass ; file Explorer
^+e::
revert_clipboard := clipboardAll
clipboard =
send ^{c}
clipWait, 0.3
sublime_path := portable_apps "\SublimeText3\sublime_text.exe"
if fileExist(clipboard)
run, %sublime_path% "%clipboard%", , useErrorLevel
clipboard := revert_clipboard
return
#ifWinActive
/*
[script info]
description = open a file with sublime text from windows file explorer
*/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment