Skip to content

Instantly share code, notes, and snippets.

@OKsign
Created March 22, 2018 08:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save OKsign/e580abc1dea684db946e94ce83504a4c to your computer and use it in GitHub Desktop.
Save OKsign/e580abc1dea684db946e94ce83504a4c to your computer and use it in GitHub Desktop.
<?xml version="1.0"?>
<root>
<vkopenurldef>
<name>KeyCode::VK_OPEN_URL_89</name>
<url type="shell">
osascript -e '
set sName to "89"
tell application "System Events"
tell process "SystemUIServer"
click (menu bar item 1 of menu bar 1 whose description is "AppleScript")
end tell
delay 0.2
tell application "System Events"
keystroke sName
delay 0.2
key code 36
end tell
end tell
'
</url>
</vkopenurldef>
<item>
<name>My Key 89: Copy Text from Web Browser to Specific App Based on Word_Hold T</name>
<identifier>Copy Text from Web Browser to Specific App Based on Word_Hold T</identifier>
<only>FIREFOX,SAFARI,GOOGLE_CHROME,OPERA</only>
<autogen>
--HoldingKeyToKey--
KeyCode::T, ModifierFlag::NONE,
@begin
KeyCode::T,
@end
@begin
<!-- run via script menu -->
KeyCode::VK_OPEN_URL_89,
@end
Option::NOREPEAT,
</autogen>
</item>
</root>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment