<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Espanso on Janusworx</title><link>https://janusworx.com/tags/espanso/</link><description>Recent content in Espanso on Janusworx</description><generator>Hugo -- gohugo.io</generator><language>en</language><managingEditor>feedback@janusworx.com (Mario Jason Braganza)</managingEditor><webMaster>feedback@janusworx.com (Mario Jason Braganza)</webMaster><copyright>© 2026, Mario Jason Braganza</copyright><lastBuildDate>Sun, 19 Jan 2025 12:45:09 +0530</lastBuildDate><atom:link href="https://janusworx.com/tags/espanso/index.xml" rel="self" type="application/rss+xml"/><item><title>More Espanso &amp; Emacs Shenanigans</title><link>https://janusworx.com/work/more-espanso-emacs-shenanigans/</link><pubDate>Sun, 19 Jan 2025 12:45:09 +0530</pubDate><author>feedback@janusworx.com (Mario Jason Braganza)</author><guid>https://janusworx.com/work/more-espanso-emacs-shenanigans/</guid><description>&lt;p&gt;&lt;br&gt;


&lt;figure&gt;
 &lt;img class="my-0 rounded-md" src="https://janusworx.com/images/2024/espanso.png" alt="Espanso Logo" /&gt;
 
 
 &lt;/figure&gt;&lt;/p&gt;
&lt;hr style='margin-left: auto; margin-right: auto; margin-bottom: 40px; margin-top: 50px; width:100px; border: none; background-color:rgb(238, 238, 238); color: rgb(238, 238, 238); height: 1px;'/&gt;

&lt;p&gt;Now that I use my local machine to draft all my posts, desktop Emacs makes everything easier … with one exception. It swallows up a lot of my Espanso expansions.&lt;/p&gt;
&lt;p&gt;My current bugbear is that it will not render a &lt;code&gt;=&lt;/code&gt; when expanding.&lt;br&gt;
I know this is entirely something that I brought on myself, and neither Emacs or Espanso in isolation will have issues.&lt;/p&gt;
&lt;p&gt;My workaround after rummaging through Espanso’s documentation was to set the backend to use &lt;code&gt;xdotool&lt;/code&gt;, in my config. (&lt;code&gt;~/.config/espanso/config/default.yml&lt;/code&gt;)&lt;/p&gt;
&lt;div class="highlight-wrapper"&gt;&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-yaml" data-lang="yaml"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="nt"&gt;x11_use_xdotool_backend&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;true&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;One downside now is that it no longer &lt;a href="https://espanso.org/docs/matches/basics/#cursor-hints" target="_blank" rel="noreferrer"&gt;jumps back to a predefined location&lt;/a&gt; in the snippets where I’ve defined such a thing. No matter. I use them rarely and I’ll figure something out later. (Alongside why desktop emacs won’t render markdown expansions sometimes as well)&lt;/p&gt;
&lt;p&gt;For now, most of my expansions work. Hurrah!&lt;/p&gt;
&lt;p&gt;&lt;hr style='margin-left: auto; margin-right: auto; margin-bottom: 40px; margin-top: 50px; width:100px; border: none; background-color:rgb(238, 238, 238); color: rgb(238, 238, 238); height: 1px;'/&gt;

Feedback on this post?&lt;br&gt;
Mail me at &lt;a href="mailto:feebdback@janusworx.com?subject=%22Feedback on post: More Espanso &amp;amp; Emacs Shenanigans
%22" &gt;feedback at this domain&lt;/a&gt; &lt;em&gt;or&lt;/em&gt; [continue the discourse here][3].
&lt;br&gt;

&lt;br&gt;

P.S. Subscribe to my &lt;a href="https://janusworx.com/subscribe/" target="_blank" rel="noreferrer"&gt;mailing list!&lt;/a&gt;&lt;br&gt;
Forward these posts and letters to your friends and get them to subscribe!&lt;br&gt;
P.P.S. Feed my &lt;a href="https://www.amazon.in/hz/wishlist/ls/2QAUKHHAMOOVS?ref_=wl_share" target="_blank" rel="noreferrer"&gt;insatiable reading habit.&lt;/a&gt;&lt;/p&gt;</description></item><item><title>Fixing Espanso Expansions</title><link>https://janusworx.com/work/fixing-espanso-expansions/</link><pubDate>Sun, 29 Sep 2024 17:05:19 +0530</pubDate><author>feedback@janusworx.com (Mario Jason Braganza)</author><guid>https://janusworx.com/work/fixing-espanso-expansions/</guid><description>&lt;p&gt;&lt;br&gt;


&lt;figure&gt;
 &lt;img class="my-0 rounded-md" src="https://janusworx.com/images/2024/espanso.png" alt="" /&gt;
 
 
 &lt;/figure&gt;
&lt;hr style='margin-left: auto; margin-right: auto; margin-bottom: 40px; margin-top: 50px; width:100px; border: none; background-color:rgb(238, 238, 238); color: rgb(238, 238, 238); height: 1px;'/&gt;
&lt;/p&gt;
&lt;p&gt;I never had the time to deal with my &lt;a href="https://espanso.org/" target="_blank" rel="noreferrer"&gt;Espanso&lt;/a&gt;&lt;sup id="fnref:1"&gt;&lt;a href="#fn:1" class="footnote-ref" role="doc-noteref"&gt;1&lt;/a&gt;&lt;/sup&gt; hijinks until today.&lt;br&gt;
While it worked perfectly, when I installed it all those years ago, when I migrated over from the Mac, Espanso itself has changed and evolved over the years.&lt;br&gt;
It took over my old configuration like a champ and &lt;em&gt;mostly&lt;/em&gt; worked, with the exception of a few shortcuts; ones that I &lt;em&gt;frequently&lt;/em&gt; used 😂&lt;/p&gt;
&lt;p&gt;Emacs was one application of mine that never quite worked right with Espanso.&lt;br&gt;
I’d frequently get &lt;code&gt;timed out waiting for reply from selection owner&lt;/code&gt; whenever I tried expansions in there. Typing :joy to get 😂 would work in every other program, but no joy with Emacs, in additon to plenty of other expansions err … not expanding.&lt;/p&gt;
&lt;p&gt;All my browser url expansions would not expand properly either, with mangled expansions most of the time.&lt;/p&gt;
&lt;p&gt;So today I &lt;a href="https://espanso.org/docs/" target="_blank" rel="noreferrer"&gt;dove in to the docs&lt;/a&gt;, and realised two things.&lt;br&gt;
1. My emacs needed a longer time out&lt;br&gt;
2. Espanso now tries to identify the &lt;em&gt;kind&lt;/em&gt; of text, and maybe those were causing my issues?&lt;/p&gt;
&lt;br&gt;


&lt;h3 class="relative group"&gt;Emacs
 &lt;div id="emacs" class="anchor"&gt;&lt;/div&gt;
 
 &lt;span
 class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;
 &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#emacs" aria-label="Anchor"&gt;#&lt;/a&gt;
 &lt;/span&gt;
 
&lt;/h3&gt;
&lt;p&gt;I realised I needed a longer clipboard threshold, only for Emacs.&lt;br&gt;
So I created an &lt;a href="https://espanso.org/docs/configuration/app-specific-configurations/" target="_blank" rel="noreferrer"&gt;App specific configuration&lt;/a&gt;, just for Emacs to use and gave it said option. Here’s what the contents of my &lt;code&gt;espanso/config/emacs.yml&lt;/code&gt; look like&lt;/p&gt;
&lt;div class="highlight-wrapper"&gt;&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-yaml" data-lang="yaml"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="nt"&gt;filter_class&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;Emacs&amp;#39;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="nt"&gt;clipboard_threshold&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="m"&gt;10000&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;
&lt;br&gt;


&lt;h3 class="relative group"&gt;Rich Text Expansions
 &lt;div id="rich-text-expansions" class="anchor"&gt;&lt;/div&gt;
 
 &lt;span
 class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;
 &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#rich-text-expansions" aria-label="Anchor"&gt;#&lt;/a&gt;
 &lt;/span&gt;
 
&lt;/h3&gt;
&lt;p&gt;That helped with a lot of expansions in Emacs, but not with my joy expansion.&lt;br&gt;
And not with stuff that were links and oh … links! and html! and markdown! Could those be the culprits?&lt;sup id="fnref:2"&gt;&lt;a href="#fn:2" class="footnote-ref" role="doc-noteref"&gt;2&lt;/a&gt;&lt;/sup&gt;&lt;br&gt;
The docs mention that Espanso now has &lt;a href="https://espanso.org/docs/matches/basics/#rich-text" target="_blank" rel="noreferrer"&gt;rich text support&lt;/a&gt;&lt;br&gt;
What that means, is that the trigger nows supports two new keywords &lt;code&gt;html&lt;/code&gt; and &lt;code&gt;markdown&lt;/code&gt; in addition ye ole &lt;code&gt;replace&lt;/code&gt;
So I changed most of my affected shortcuts to either of those two keywords; &lt;code&gt;markdown&lt;/code&gt; for most everything and &lt;code&gt;html&lt;/code&gt; for linky stuff. Here’s what my beloved joy looks like now …&lt;/p&gt;
&lt;div class="highlight-wrapper"&gt;&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-yaml" data-lang="yaml"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="nt"&gt;matches&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;- &lt;span class="nt"&gt;trigger&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;&amp;#34;:joy&amp;#34;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;markdown&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="l"&gt;😂&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&lt;br&gt;

And those two things did it! Every shortcut expands everwhere! What joy 😂&lt;/p&gt;
&lt;p&gt;&lt;hr style='margin-left: auto; margin-right: auto; margin-bottom: 40px; margin-top: 50px; width:100px; border: none; background-color:rgb(238, 238, 238); color: rgb(238, 238, 238); height: 1px;'/&gt;

Feedback on this post?&lt;br&gt;
Mail me at &lt;a href="mailto:feebdback@janusworx.com?subjectFeedback on post: Fixing Espanso Expansions
%22" &gt;feedback at this domain&lt;/a&gt; &lt;em&gt;or&lt;/em&gt; [continue the discourse here][3].
&lt;br&gt;

&lt;br&gt;

P.S. Subscribe to my &lt;a href="https://janusworx.com/subscribe/" target="_blank" rel="noreferrer"&gt;mailing list!&lt;/a&gt;&lt;br&gt;
Forward these posts and letters to your friends and get them to subscribe!&lt;br&gt;
P.P.S. Feed my &lt;a href="https://www.amazon.in/hz/wishlist/ls/2QAUKHHAMOOVS?ref_l_share" target="_blank" rel="noreferrer"&gt;insatiable reading habit.&lt;/a&gt;&lt;/p&gt;
&lt;div class="footnotes" role="doc-endnotes"&gt;
&lt;hr&gt;
&lt;ol&gt;
&lt;li id="fn:1"&gt;
&lt;p&gt;Espanso lets you assign short snippets of text to longer streams of text, that you’d frequently use. I use &lt;code&gt;:adhx&lt;/code&gt; for example, and it expands out to type my whole address. Pretty handy!&amp;#160;&lt;a href="#fnref:1" class="footnote-backref" role="doc-backlink"&gt;&amp;#x21a9;&amp;#xfe0e;&lt;/a&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li id="fn:2"&gt;
&lt;p&gt;dun! dun! dun! they were!&amp;#160;&lt;a href="#fnref:2" class="footnote-backref" role="doc-backlink"&gt;&amp;#x21a9;&amp;#xfe0e;&lt;/a&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;/div&gt;</description></item></channel></rss>