diff --git a/dot_config/hammerspoon/init.lua b/dot_config/hammerspoon/init.lua index 6722d4b..f5a9ad3 100644 --- a/dot_config/hammerspoon/init.lua +++ b/dot_config/hammerspoon/init.lua @@ -1,3 +1,17 @@ +-- Auto-hide WezTerm when it loses focus +weztermAppWatcher = hs.application.watcher.new(function(appName, eventType, appObject) + if eventType == hs.application.watcher.deactivated and appName == "WezTerm" then + print("WezTerm lost focus, hiding...") + appObject:hide() + end +end) +weztermAppWatcher:start() + +print("WezTerm auto-hide enabled") + + + + -- Function to simulate key presses local function pressFn(mods, key) if key == nil then