Created
April 16, 2025 14:18
-
-
Save amirrajan/5c256e4eb5390f11586a90685873c9d8 to your computer and use it in GitHub Desktop.
hammer spoon ctrl+t to swap bettween windows
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
require("hs.ipc") | |
hs.hotkey.bind({'ctrl'}, "t", function() | |
app_name = hs.application.frontmostApplication():name() | |
if app_name == 'Alacritty' then | |
hs.osascript.applescript('tell application "Chrome" to activate') | |
else | |
hs.osascript.applescript('tell application "Alacritty" to activate') | |
end | |
end) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment