Skip to content

Instantly share code, notes, and snippets.

@thugcee
Created August 11, 2023 17:12
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 thugcee/78d72739d02fc6170b27e5f1a503dd23 to your computer and use it in GitHub Desktop.
Save thugcee/78d72739d02fc6170b27e5f1a503dd23 to your computer and use it in GitHub Desktop.
my attempt to make MS Windows usable using autohotkey - hotkeys to directly switch to my most frequently used windows
#SingleInstance force
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
#Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
#c::Run, "C:\Program Files (x86)\CopyQ\copyq.exe" toggle
#PgDn::WinSet, Bottom,, A
#w::CycleExe("firefox.exe", "firefox")
#q::WinActivate, ahk_exe WindowsTerminal.exe
#a::CycleExe("idea64.exe", "idea")
#s::WinActivate, ahk_exe Postman.exe
#x::CycleExe("Teams.exe", "teams")
#t::CycleExe("Teams.exe", "teams")
#n::WinActivate, ahk_exe notepad++.exe
#+f::WinActivate, ahk_class CabinetWClass ahk_exe explorer.exe
#f::WinActivate, ahk_exe TE64.exe
#m::WinActivate, ahk_exe OUTLOOK.EXE
#o::WinActivate, ahk_exe Logseq.exe
#F2::WinActivate, ahk_exe Logseq.exe
#d::WinActivate, ahk_exe dbeaver.exe
#z::CycleExe("code.exe", "code")
<#p::ToolTip, assigned to <#p
LWin Up::
IF A_PriorKey = LWin
Send {Blind}{Ctrl}
Return
CycleExe(exe, group) {
GroupAdd, %group%, ahk_exe %exe%
if WinActive("ahk_exe " exe)
GroupActivate, %group%, r
else
WinActivate ahk_exe %exe%
Return
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment