[hammerspoon] clicking on quitter notification re-launches app

pull/39/head
Alpha Chen 3 years ago
parent 045e47898c
commit 4f0f9e94d2

@ -100,11 +100,14 @@ function obj:reap()
local app = hs.application.get(appName) local app = hs.application.get(appName)
if self:shouldQuit(app) then if self:shouldQuit(app) then
hs.notify.new({ hs.notify.new(
function() hs.application.open(app:name()) end,
{
title = "Hammerspoon", title = "Hammerspoon",
informativeText = "Quitting " .. app:name(), informativeText = "Quitting " .. app:name(),
withdrawAfter = 2, withdrawAfter = 2,
}):send() }
):send()
app:kill() app:kill()
self.lastFocused[app:name()] = nil self.lastFocused[app:name()] = nil
end end

Loading…
Cancel
Save