facilethings capture prompt
This commit is contained in:
parent
4e463149a5
commit
acd17514fd
1 changed files with 27 additions and 0 deletions
|
|
@ -438,3 +438,30 @@ end)
|
||||||
--
|
--
|
||||||
-- hs.hotkey.bind(modifiers.clipboard, "v", function() clipboard:toggleClipboard() end)
|
-- hs.hotkey.bind(modifiers.clipboard, "v", function() clipboard:toggleClipboard() end)
|
||||||
-- hs.hotkey.bind(modifiers.clipboard, hs.keycodes.map.delete, function() clipboard:clearAll() end)
|
-- hs.hotkey.bind(modifiers.clipboard, hs.keycodes.map.delete, function() clipboard:clearAll() end)
|
||||||
|
|
||||||
|
----------------------------------------------------------------------------------------------------
|
||||||
|
-- Facilethings paste
|
||||||
|
----------------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
local function facileCaptpure()
|
||||||
|
ok,text = hs.dialog.textPrompt("Facilethings","Capture")
|
||||||
|
if ok then
|
||||||
|
hs.osascript.applescript(string.format([[
|
||||||
|
tell application "Mail"
|
||||||
|
|
||||||
|
##Create the message
|
||||||
|
set theMessage to make new outgoing message with properties {subject:"%s", content:"", visible:true}
|
||||||
|
|
||||||
|
##Set a recipient
|
||||||
|
tell theMessage
|
||||||
|
make new to recipient with properties {name:"inbox@facilethings.com", address:"inbox@facilethings.com"}
|
||||||
|
|
||||||
|
##Send the Message
|
||||||
|
send
|
||||||
|
|
||||||
|
end tell
|
||||||
|
end tell
|
||||||
|
]], text))
|
||||||
|
end
|
||||||
|
end
|
||||||
|
hs.hotkey.bind(modifiers.window, "f",facileCaptpure)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue