Espanso text expander

Editing the default phrases file for espanso in Sublime Text 4.

If you are not already using a text expander application then I highly recommend that you start. It will save you hundreds, if not thousands, of keystrokes every month.

As the name suggests, a text expander application is a utility that runs in the background and looks out for you typing predefined phrases which it then replaces with usually a longer text version.

For example, when I type --@e, my text expander replaces this with my full email address:, saving me 25 keystrokes.

I have another that outputs my email signature, one for my phone number, my full name, my address, my postcode. I have a bunch defined to output accented letters often used in Spanish: á, é, í, ó, ú, ñ, as well as ¡ and ¿. Other typographical regulars of mine that I’ve created shortcuts for are ½, ⅓, ⅔, ¼, ¾, ° (degrees), — (em dash), – (en dash) and × (multiplication).

Then there are dynamically generated dates that I have defined. Typing --today right now gives me Saturday 31 July 2021. I also have shortcuts set for yesterday, tomorrow and now, which includes the time in 24-hour format.

And what about emoji? In Windows, I can press Win+. (full stop) to bring up an emoji picker, but how much simpler if I can simply type 😥 and for this to be replaced with 😢, or :happy: to see 😀.

For the last few years, my go-to text expander has been PhraseExpress. It has a simple and fairly intuitive graphical interface. If you are a Windows user and not comfortable with code, then this is a good place to start.

This week, I moved to the open-source, cross-platform espanso.

Editing your key phrases and replacement text in espanso is not as user-friendly as PhraseExpress. It requires locating and editing a YAML file. For example, here is a snippet from my default.yml file that handles Spanish accented characters:

# Spanish

    - trigger: "--!"
      replace: "¡"

    - trigger: "--?"
      replace: "¿"

    - trigger: "a''"
      replace: "á"

    - trigger: "e''"
      replace: "é"

One of the main reasons for my move to espanso is that I am now using my Asus ZenBook more dual booting between Elementary OS (Linux) and Windows 10, and I wanted to be able to share phrases between both installations. As espanso is cross-platform (Windows, Linux and Mac OS), I can do that.

To make things even easier, I am managing my YAML phrase file in GitHub and so can easily pull down my latest edits no matter what platform or machine I am working on.

Published by

Gareth Saunders

I’m Gareth J M Saunders, 52 years old, 6′ 4″, father of 3 boys (including twins). Enneagram type FOUR and introvert (INFP), I am a non-stipendiary priest in the Scottish Episcopal Church, I sing with the NYCGB alumni choir, play guitar, play mahjong, write, draw and laugh… Scrum master at Safeguard Global; latterly at Sky and Vision/Cegedim. Former web architect and agile project manager at the University of St Andrews and previously warden at Agnes Blackadder Hall.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.