Created
May 6, 2017 20:56
-
-
Save casprwang/1c2b4a71bc9f8d449800c76c3f369d05 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- disable alt-v for Adobe's built-in shortcut | |
function applicationWatcher(appName, eventType, appObject) | |
if (eventType == hs.application.watcher.activated) then | |
if (string.find(appName, 'iTerm')) then | |
for i,v in pairs(editting) do | |
v:disable() | |
end | |
-- editting.cD:disable() | |
else | |
for i,v in pairs(editting) do | |
v:disable() | |
end | |
-- editting.cD:enable() | |
end | |
if (string.find(appName, 'Adobe')) then | |
altV:disable() | |
else | |
altV:enable() | |
end | |
end | |
end | |
-- end | |
local appWatcher = hs.application.watcher.new(applicationWatcher) | |
appWatcher:start() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment