You're welcome :)
My advice would be setting up a python script that evaluates the argument as an expression. Take a look at https://espanso.org/docs/passive-mode/#integration-with-shell for an example.
Cheers :)
Fully agreed!
Not saying OP specifically, but any user should consider donating a bit if they can:
Just shot over some bucks again because this reminded me of it :)
If you're using the default config, you have probably hit the ALT-key twice, which disables it. If you look at the documentation (here specifically, in the section 'toggle_key
'), there's an option 'OFF
' at the bottom, which I assume is used to disable the toggle_key
functionality. If not you could try to choose another key, which you'll less likely hit twice by accident, preventing it from disabling.
For those that find trouble trying to completely uninstall espanso I would suggest to follow the steps proposed by Federico to uninstall legacy version of the app. Those worked for me after a while trying lots of other things
Hey,
Thank you for the feedback!
I think you should be able to use a workaround, but first you'll need to upgrade to v2: https://github.com/federico-terzi/espanso/issues/594#issuecomment-939329339
Then, you can create an app-specific config that disables the all-emojis package: https://espanso.org/docs/next/configuration/include-and-exclude/
For example, create a file in "$CONFIG/config/searchworkaround.yml" with this content:
filter_title: "SEARCHWORKAROUND"
extra_excludes:
- "../match/packages/all-emojis/*"
Finally, you should be able to call the list command with the proper parameter:
espanso match list --title "SEARCHWORKAROUND"
Cheers :)
The getting started page covers this: https://espanso.org/docs/get-started/
In short, you'll need to edit configuration files to use it. I understand this is not particularly user-friendly, and therefore a GUI is planned, though it's not ready yet :)
Dear Espanso developers,
Thanks a lot!!! ... I really loved your previous version... I just updated to 0.7.3 through chocolatey.org installer and the program no longer starts on my machine Win10 English with win10debloater ... tried reinstalling and I am unable to make it run again. Please how can I troubleshoot this?
Hey,
I'm sorry you experienced this problem! If you are on a M1 machine, you should install the alpha v2, which ships with proper support for the new architecture.
Please see here: https://github.com/federico-terzi/espanso/issues/594#issuecomment-939329339 And install from here (choose the Alpha version): https://espanso.org/install/
Cheers :)
Hey,
Thank you for the feedback!
> I have an expansion that saves clipboard data to a json if it matches a URL regex, but it would be good to not require an additional trigger to store this data.
What would a trigger look like in your case? The stable version only support static triggers, whereas the new alpha v2 also supports dynamic ones through regexes: https://espanso.org/docs/next/matches/regex-triggers/ Not sure if that can solve your use-case :)
> Another question is whether CTRL+A, ALT+A, etc. can be included in triggers as well.
I'm not sure I understand, would you like your trigger (the text you type to trigger an expansion) to also include keyboard shortcuts? We had a similar feature request to support keyboard shortcuts as triggers, though I don't think that would cover your use-case: https://github.com/federico-terzi/espanso/issues/383
Cheers :)
Hey,
I don't think I've completely understood your use-case, but if your AI service offers an HTTP API you might be able to inject the AI output with espanso like this example: https://espanso.org/docs/matches/#shell-extension
Cheers :)
Hey,
> If I could use capture groups as part of regex triggers, then I wouldn't need to use forms. Something like this:
You definitely can! Though you'll need to use named groups
The regex section of the docs is not completed yet, but I've just added the chapter on these topics :) https://espanso.org/docs/next/matches/regex-triggers/#arguments
(refresh the page if you don't see it)
Cheers :)
I wonder if passive mode might help - https://espanso.org/docs/passive-mode/
I don't think it's possible to delay actions in Espanso, but I'm not sure. Otherwise, my suggestion would be to just paste in from another app that doesn't have Freshdesk's bad editor.
> And when I type :greet/Jon/, select, and hit ctrl on the mac
Are you double-pressing the CTRL key? :)
Also, keep in mind that passive mode is going away in the next version and will be replaced with regex triggers (which are much more powerful in most situations).
So your best bet is to not rely too much on passive mode right now, and instead prefer Forms or wait for the v2 alpha to become more stable :)
Try creating a file called timestamp.yml in your user folder. Any edits to the date formatting can be found here
name: timestamp parent: default
matches: - trigger: ":ts" replace: "{{mydate}},{{mytime}}, FName LName" vars: - name: mydate type: date params: format: "%m/%d/%Y" - name: mytime type: date params: format: "%_H:%M:%S"
Without knowing precisely what you want, yes, you can certainly do this.
As for an example, the multi-line example in the documentation should be everything you need.
- trigger: "include newlines" replace: | exactly as you see will appear these three lines of poetry
That's obviously not a newsletter yet, but even if there were a newsletter example, it wouldn't be in the format you want.
Hey,
Thank you for the feedback! This is not currently possible, but I'd like to know a bit more details to see if we could make a feature out of it :)
One thing I don't understand is: if you select some text and then type the trigger, wouldn't the selection "unselect"?
As a possible workaround, you could first copy the selection with CTRL+C and then use the clipboard extension: https://espanso.org/docs/matches/#clipboard-extension
Cheers :)
Great! For one-note, try to add a onenote.yml
file in the CONFIG\user folder with this content:
filter_title: OneNote
backspace_delay: 10
Let me know if that helps! Otherwise, you'll need to create a custom patch by following this process: https://github.com/federico-terzi/espanso/issues/248#issuecomment-624258027 and https://espanso.org/docs/configuration/#application-specific-configurations
Cheers :)
In order to use the clipboard, you will need to use the verbose syntax (see here: https://espanso.org/docs/forms/#using-with-script-and-shell-extension).
An example could be (not tested);
- trigger: ":trigger"
replace: "Words before clipboard {{clipboard}} choose something: {{form1.name}}"
vars:
- name: clipboard
type: clipboard
- name: form1
type: form
params:
layout: |
Choose something {{name}}
Hey,
Yes, you should be able to do it with something like:
- trigger: ":reversed"
replace: "{{myshell}}"
vars:
- name: clipboard
type: clipboard
- name: myshell
type: shell
params:
cmd: "echo $ESPANSO_CLIPBOARD | rev"
For more information, read the "Advanced Topics" section: https://espanso.org/docs/matches/#advanced-topics
Cheers :)
Hey,
Your best bet is to look at the Date extension
In your case, you could use:
- trigger: ":time"
replace: "{{mytime}}"
vars:
- name: mytime
type: date
params:
format: "%H:%M"
You can also change the format of the output date by changing the format
parameter, according to the chrono documentation
Cheers :)
Hey,
Thank you for the interest!
The key takeaway is that backslashes should be escaped (note the double backslash), such as:
- trigger: ":vnc"
replace: "{{output}}"
vars:
- name: output
type: shell
params:
cmd: 'C:\\Program Files\\uvnc bvba\\UltraVNC\\vncviewer.exe'
inject_args: true
> I have no idea how to pass the IP as an argument when I type :vnc IP I type
Unfortunately, this is not possible yet (these are called active mode arguments, which I'm currently experimenting with).
Your best bet is to use Forms. For example, you could do:
- trigger: ":vnc"
replace: "{{output}}"
vars:
- name: form1
type: form
params:
layout: |
VNC IP {{ip}}
- name: output
type: shell
params:
cmd: "C:\\Program Files\\uvnc bvba\\UltraVNC\\vncviewer.exe %ESPANSO_FORM1_IP%"
shell: "cmd"
I haven't tested it, but it should be a good starting point!
Cheers :)
Hey, Thanks for reporting this issue! Indeed, this behavior is quite strange. Could you please try changing the espanso toggle_key to something else and see if the problem remains?
Cheers :)
Hey,
If you want to use the brackets inside replacements, you have to escape them with backslashes. Such as:
- trigger: ":hi"
replace: "Hi \\{\\{you\\}\\}!"
which produces "Hi {{you}}!" when expanded. Keep in mind that here we used a double backslash to escape the brackets as it was inside a YAML string (as we used double quotes). If you don't put the quotes (for example in a multiline replacement), you will need to put only one backslash:
- trigger: ":hi"
replace: |
Hi
\{\{you\}\}!
> Also, it will be awesome if you can share me some link how to use variables and set up {{date}} for example.
Your best bet is the docs: https://espanso.org/docs/matches/#date-extension
Cheers :)
Glad to hear that!
> Is it possible to control the look and feel of the pop-up form window? Esp., the lengths of individual fields. (I'm thinking of fields for book titles, etc.)
Not at the moment, but you can open a feature request on Github!
> Can forms be named and nested? E.g., define say 3 forms in a parent yml file, and invoke them in any of a dozen child files.
You should be able to do that by defining them as global variables: https://espanso.org/docs/matches/#global-variables
Forms are just another type of variable, so as long as you declare them globally, you can use them in any match. You can also use multiple forms for each match, and they will show in sequence.
Cheers :)
Hey, You can disable the notification with these steps: https://espanso.org/docs/configuration/#macos-notification-for-secureinput
Keep in mind that this will not disable firefox activating secure input, which means that in those cases, espanso will not be able to work. You will not be notified though.
Cheers :)
Hey,
That's pretty strange. You could either change the toggle_key
or disable it entirely: https://espanso.org/docs/configuration/#customizing-the-toggle-key
If you disable it entirely, you can then set up a custom shortcut (within you Mint settings) to call the command espanso cmd toggle
Cheers :)
On macOS you could get mainly two types of notifications: * General notifications (enabled/disabled/invalid syntax/ecc) * Secure Input notifications
To understand why the latter are there, refer to the docs: https://espanso.org/docs/configuration/#macos-notification-for-secureinput
You can either disable only the secure input ones or both of them.
https://espanso.org/docs/configuration/#hiding-the-notifications
Oh thanks. Didn't know about https://docs.rs/chrono/
That documentation should be put in reddit sidebar or anywhere in https://espanso.org/
But, there is no time
type though, using date
instead.
Personally, I only care for Android. TextEnpander seems to exist in some form for iOS, so there might be some chance: https://textexpander.com/help/mobile/intro.html If it's worth going for iOS is a totally different question, though :)
Thanks for replying and following up!
I did it the way you're doing it at first. It worked, but I decided it'd be better to keep the templates in their own markdown files and have espanso insert the contents of the files. The benefits are that it's much easier to edit the templates and I don't have to manually propagate edits or new templates. (Although I do need to add a link if I make a new template for a new type of note, so it still isn't perfect.)
It looks like you don't use as many templates, so the value of my method probably isn't the same for you, but I'll provide it in case you want it.
Anyway, thanks again!
Heya. Thanks again for helping me with this.
This is the file I use on macOS. It works perfectly.
However, I've been unable to make an equivalent file for windows. (I put notes about what I already tried directly in the pastebin.) When you have a chance, would you please let me know if you can see why it isn't working?
Yeah, this is pretty sweet. You deserve more upvotes. I'm using Obsidian for my Markdown mindbase and it as yet has only one built-in template, for "Today's Note." Your idea opens up unlimited custom templates... my mind is blowing.