3 ms·
I use a tool called "Espanso" to accomplish something similar at work. It only runs locally, so no weird data scraping issues to worry about. And it's easy to u
by UtopiaPunk 3y ago
I use a tool called "Espanso" to accomplish something similar at work. It only runs locally, so no weird data scraping issues to worry about. And it's easy to update as things changes because everything lives in a simple yml file.
https://espanso.org/ https://espanso.org/
It can do simple text replacement, so I have words, phrases, and sentences I use frequently compressed into a few keyboard clicks. It can also grab what is in your clipboard, so that can be incorporated into responses, which is simple but very handy.
A simple text replacement looks like this in the yml file:
- trigger: ":espanso"
replace: "Hi there!"
But it can even work with a shell, which I think is amazing! For example, I have a particular task at work where I often need to insert a random number into a text document. I can have Espano run PowerShell behind the scenes to run a simple PowerShell command, and that looks something like:
- trigger: ";rand"
replace: " {{output}}"
vars:
- name: output
type: shell
params:
cmd: "Get-Random -Minimum 100000"
shell: powershell
- Xeophon 3y agoI love espanso. I live it over AHK as it doesn't have some obscure and hard to learn language, so I can just write some python scripts and trigger them with espanso.
- eschluntz 3y agoThat is cool! I use Autokey under the hood, but I'll check out Espanso as well
- deleted 3y ago[deleted]
- n8henrie 3y agoLove espanso, I use it in Mac, Linux, and Windows! The creator is also incredibly nice, one of those rare open source devs that seems to go out of his way to validate concerns and make PRs truly feel welcome. Great project.
- karencarits 3y agoA sidenote, but Espanso can also be set up to communicate with eg chatgpt; you copy some text and type a trigger word such as ":ask" or ":debug" and it makes a request from the trigger and the clipboard and returns the reply from openai https://github.com/rohitna/chatgpt-script https://github.com/rohitna/chatgpt-script
- rabbitofdeath 3y agoWOW! I use Espanso and love it - this will send me off into new rabbitholes!
- replwoacause 3y agoI’ve got to plug Snippety on macOS. I’ve configured it to work with my PowerShell scripts, so I can easily call out to OpenAI endpoints and then inline the response into whatever app I’m in. Plus, the dev is super cool and his product is well done. Not associated with it in anyway other than being a happy customer. https://snippety.app https://snippety.app