<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Al Amin on Productivity Tools]]></title><description><![CDATA[Al Amin on Productivity Tools]]></description><link>https://alaminik.hashnode.dev</link><generator>RSS for Node</generator><lastBuildDate>Sat, 24 Oct 2026 17:19:28 GMT</lastBuildDate><atom:link href="https://alaminik.hashnode.dev/rss.xml" rel="self" type="application/rss+xml"/><language><![CDATA[en]]></language><ttl>60</ttl><item><title><![CDATA[Clipboard History on Linux: How It Works on X11 and Wayland, and How to Sync It With Your Phone]]></title><description><![CDATA[How clipboard history on Linux works: X11 selections, Wayland data-control, common clipboard managers, and a GUI that syncs text with Android.]]></description><link>https://alaminik.hashnode.dev/clipboard-history-on-linux</link><guid isPermaLink="true">https://alaminik.hashnode.dev/clipboard-history-on-linux</guid><category><![CDATA[Linux]]></category><category><![CDATA[Productivity]]></category><category><![CDATA[tools]]></category><category><![CDATA[devtools]]></category><category><![CDATA[wayland]]></category><dc:creator><![CDATA[Al Amin]]></dc:creator><pubDate>Thu, 22 Oct 2026 12:42:23 GMT</pubDate><content:encoded><![CDATA[<p>If you have ever copied a command, closed the terminal, and then found the clipboard empty, you have already met the main reason people go looking for clipboard history on Linux. The Linux clipboard is not a storage box. It is a promise from one app to hand over data when another app asks for it, and when that app goes away, so does the promise.</p>
<p>This post explains what happens under the hood on X11 and Wayland, what clipboard managers do about it, and the GUI setup I use to get copied text onto my phone too.</p>
<h2>How the clipboard works on Linux (and why copies vanish)</h2>
<p>On X11 there is no central clipboard buffer. When you copy, the app announces that it owns a "selection". When you paste, the receiving app asks the owner for the data in a format it understands. Nothing is stored anywhere else.</p>
<p>That design has two side effects developers run into all the time:</p>
<ol>
<li><strong>Copied text can disappear.</strong> If the owning app exits, there is no owner left to answer the paste request.</li>
<li><strong>There are two clipboards.</strong> X11 has a PRIMARY selection (whatever you last highlighted, pasted with a middle click) and a CLIPBOARD selection (the one you fill with Ctrl+C). They are independent, which is why middle-click paste sometimes gives you something you did not expect.</li>
</ol>
<p>Wayland keeps the same ownership model, with one big change: apps are isolated. Under the core protocol, only the window that has keyboard focus can read the clipboard. That is good for security and awkward for any tool that wants to watch the clipboard in the background.</p>
<h2>What a clipboard manager on Linux actually does</h2>
<p>A clipboard manager fixes both problems by acting as a permanent participant. It watches for new selections, copies the data into its own history, and can take ownership itself so the content survives after the source app closes. Then it gives you a way to search and paste older items.</p>
<p>On X11 this is simple, because any client can observe selections. On Wayland, a background tool needs a privileged extension called a data-control protocol. There are two versions in use: the older wlroots one and a newer standardized one. Support differs by compositor. wlroots-based compositors such as Sway and Hyprland support data control, and KDE Plasma supports the standardized version. GNOME's compositor has historically offered neither, which is why most GNOME clipboard tools are shell extensions that run inside the desktop itself.</p>
<p>The quick way to know which world you are in: run <code>echo $XDG_SESSION_TYPE</code> in a terminal. It prints <code>x11</code> or <code>wayland</code>.</p>
<h2>Common ways to get clipboard history on Linux</h2>
<p>Here is how the usual options compare. "Phone sync" means getting copied text onto an Android phone without extra tooling.</p>
<table>
<thead>
<tr>
<th>Option</th>
<th>What it is</th>
<th>Session</th>
<th>Phone sync</th>
</tr>
</thead>
<tbody><tr>
<td>cliphist + wl-clipboard</td>
<td>Small CLI that stores history from <code>wl-paste</code> and lets you pick with a launcher menu</td>
<td>Wayland compositors with data control</td>
<td>No</td>
</tr>
<tr>
<td>CopyQ</td>
<td>Feature-rich, scriptable clipboard manager with tabs</td>
<td>Strong on X11, more caveats on Wayland</td>
<td>No</td>
</tr>
<tr>
<td>Klipper</td>
<td>Clipboard history built into KDE Plasma</td>
<td>KDE on X11 or Wayland</td>
<td>Through KDE Connect</td>
</tr>
<tr>
<td>GNOME shell extensions</td>
<td>Clipboard history inside the GNOME panel</td>
<td>GNOME on X11 or Wayland</td>
<td>No</td>
</tr>
<tr>
<td>InsertKit</td>
<td>GUI clipboard history plus snippets and voice typing on one account</td>
<td>Linux desktop (check the dependency screen on Wayland)</td>
<td>Yes, with the Android app</td>
</tr>
</tbody></table>
<p>On Sway or Hyprland, cliphist is simple and light. On KDE, Klipper is already there. The rest of this post covers the case where you want a GUI and the same history on more than one device.</p>
<h2>A GUI clipboard history on Linux that syncs with Android</h2>
<p>I use InsertKit for this. It is a desktop app for Windows, macOS and Linux, with an Android app and a Chrome extension that sign in to the same account. On Linux it ships as an AppImage, a <code>.deb</code> and an <code>.rpm</code>. Clipboard history is one of its three main parts, next to text snippets and voice typing.</p>
<h3>1. Install, sign in, and check dependencies</h3>
<p>After installing, sign in with email and password or Google. Then open <strong>Settings â†’ General â†’ Linux Dependencies</strong>. It checks for the helper tools the app uses on Linux, such as <code>xdotool</code>, <code>wtype</code> and <code>maim</code>. On Wayland, its tips point to <code>wtype</code> or <code>ydotool</code>. Install whatever it flags, and if you are on Wayland, test in the few apps you use every day before relying on it.</p>
<h3>2. Turn on clipboard monitoring</h3>
<p>Clipboard capture is controlled by <strong>Settings â†’ Snippets â†’ Enable Clipboard Monitoring</strong>. With it on, new copies show up on the <strong>Clipboard History</strong> page automatically, with relative times like "Just now" or "5m ago". From that page you can:</p>
<ul>
<li>search your history and see the item count</li>
<li>click a row to copy it again</li>
<li>star an item so it stays pinned at the top</li>
<li>delete single items, or use <strong>Clear All</strong> (it asks for confirmation)</li>
</ul>
<h3>3. Paste old items with the popup</h3>
<p>The part I use most is the quick popup. Press <strong>Ctrl+Shift+Z</strong> anywhere and a small, draggable window opens with the search box already focused. It has three tabs: <strong>Clipboard</strong>, <strong>Snippets</strong> and <strong>Favorites</strong>. Click an item and it is copied and inserted into the app you were just using. Items are tagged as Email, Url or Text.</p>
<p>Two details worth knowing. The <strong>Pin</strong> button keeps the window open and on top after inserting, which is handy when you are pasting several items into a form. Without the pin, it hides when you click away, and <strong>Esc</strong> closes it. If Ctrl+Shift+Z clashes with a shortcut in your editor or terminal, change it in <strong>Settings â†’ General â†’ Clipboard Popup Hotkey</strong>.</p>
<h3>4. Get the same history on your phone</h3>
<p>Clipboard history syncs to your account, so text copied on the Linux desktop is available on Android and the other way round. On the phone you have a few ways to reach it:</p>
<ul>
<li>the <strong>Clipboard</strong> tab in the app, with search, favorites and Clear All</li>
<li>typing <code>/clip</code> in a text field in most apps, which opens a clipboard history overlay where you tap an item to insert it</li>
<li>the optional InsertKit Keyboard, whose clipboard button shows the latest 15 items along with the platform and source app</li>
</ul>
<p>The Chrome extension also has a Clipboard History tab and the same Ctrl+Shift+Z shortcut inside the browser.</p>
<h3>5. A few habits that keep history useful</h3>
<ul>
<li><strong>Star what you reuse.</strong> Favorites stay on top, so your staging URL or test card number is always one click away.</li>
<li><strong>Delete sensitive items.</strong> If you copy a token or password, remove it from history afterwards, or switch monitoring off before you handle secrets.</li>
<li><strong>Promote repeat copies to snippets.</strong> If you paste the same thing every day, it belongs in a snippet with a trigger like <code>/staging</code>, not in history.</li>
</ul>
<h2>Clipboard history vs. snippets on Linux</h2>
<p>These two features overlap, so it helps to define them:</p>
<ul>
<li><strong>Clipboard history</strong> is automatic and short-lived. It records what you copied so you can get back to it.</li>
<li><strong>A snippet</strong> is deliberate and permanent. You save text once and insert it by typing a trigger such as <code>/reply</code> or by picking it from a popup.</li>
</ul>
<p>Because the Ctrl+Shift+Z popup has a Snippets tab next to the Clipboard tab, I treat them as one place to look. The same app also does voice typing in 100+ languages, which is a nice bonus when I am writing longer issue comments, but clipboard history is the reason I installed it on Linux.</p>
<h2>FAQ</h2>
<h3>How do I see clipboard history on Linux?</h3>
<p>Linux does not keep a clipboard history by default. You need a clipboard manager: Klipper on KDE, a shell extension on GNOME, a CLI like cliphist on wlroots compositors, or a cross-platform GUI app. In InsertKit, open the Clipboard History page or press Ctrl+Shift+Z.</p>
<h3>Why does copied text disappear when I close an app on Linux?</h3>
<p>The app that copied the data owns it and serves it on request. When that app exits, nothing is left to answer the paste. A clipboard manager keeps its own copy, so the content survives.</p>
<h3>Does clipboard history work on Wayland?</h3>
<p>Yes, but background tools need a data-control protocol, and support differs between compositors. Check <code>$XDG_SESSION_TYPE</code>, follow your tool's Wayland notes, and test in the apps you use most.</p>
<h3>What is the difference between PRIMARY and CLIPBOARD on Linux?</h3>
<p>PRIMARY holds whatever you last highlighted and is pasted with a middle click. CLIPBOARD holds what you copied with Ctrl+C and is pasted with Ctrl+V. They are separate.</p>
<h3>Can I sync clipboard history between Linux and Android?</h3>
<p>Yes. KDE users can use KDE Connect. With InsertKit, clipboard history syncs through your account, so copies from the Linux desktop show up in the Android app and through the <code>/clip</code> overlay.</p>
<h3>Is it safe to keep passwords in clipboard history?</h3>
<p>Treat clipboard history as stored data. Delete secrets after copying them, or turn monitoring off while you work with credentials.</p>
<h2>Wrapping up</h2>
<p>Clipboard history on Linux is less mysterious once you know that the clipboard is really a hand-off between apps, and that Wayland adds a permission layer on top. Pick the tool that matches your session and desktop. If you want a GUI history that also follows you to your phone, you can try <a href="https://insertkit.com/">InsertKit's clipboard manager</a> on Linux alongside the tools you already use.</p>
]]></content:encoded></item><item><title><![CDATA[Groq Whisper Dictation in Any App: Bring Your Own API Key for Voice Typing on Windows, macOS and Linux]]></title><description><![CDATA[Use Groq Whisper or another bring-your-own-key speech API for dictation in any app on Windows, macOS and Linux, vs free hosted and offline Whisper.]]></description><link>https://alaminik.hashnode.dev/groq-whisper-dictation-byok-voice-typing</link><guid isPermaLink="true">https://alaminik.hashnode.dev/groq-whisper-dictation-byok-voice-typing</guid><category><![CDATA[Productivity]]></category><category><![CDATA[Speech Recognition]]></category><category><![CDATA[AI]]></category><category><![CDATA[tools]]></category><dc:creator><![CDATA[Al Amin]]></dc:creator><pubDate>Wed, 21 Oct 2026 12:44:36 GMT</pubDate><content:encoded><![CDATA[<h2>Why bring your own key at all?</h2>
<p>Most dictation apps hide the speech engine. You press a key, talk, and text shows up. That is fine until you want to know where your audio goes, which model is transcribing it, or what happens when you hit a daily limit.</p>
<p>"Bring your own key" (BYOK) flips that. You create an API key with a speech provider such as Groq or OpenAI, paste it into your dictation tool, and the tool sends your audio to that provider using your account. You pick the model, you see the usage on your own provider dashboard, and you can swap providers whenever you like.</p>
<p>This post walks through what a BYOK dictation setup looks like on the desktop, using Groq's hosted Whisper model as the main example, and where it fits next to free hosted engines and fully offline Whisper.</p>
<h2>What "Groq Whisper dictation" actually means</h2>
<p>Whisper is OpenAI's open speech recognition model family. Several providers host it behind an API. Groq is one of them and offers Whisper models such as <code>whisper-large-v3</code>, plus a free tier (check Groq's console for the current limits, since they change).</p>
<p>A dictation tool on its own doesn't recognize speech. It does three jobs:</p>
<ol>
<li><strong>Capture</strong>: listen to your microphone while a hotkey is active.</li>
<li><strong>Transcribe</strong>: send the audio to a speech engine (cloud API or a local model) and get text back.</li>
<li><strong>Insert</strong>: put that text at your cursor in whatever app you are using.</li>
</ol>
<p>With BYOK, step 2 runs on your own Groq (or OpenAI, Deepgram, AssemblyAI...) account.</p>
<h2>A concrete setup: Groq key in InsertKit</h2>
<p>I'll use InsertKit for the walkthrough because it is a desktop voice typing app plus text expander that runs on Windows, macOS and Linux, and its API Keys page accepts a Groq key directly. Other tools differ in the details, but the flow is similar.</p>
<ol>
<li><strong>Create a key</strong> in the Groq console and copy it.</li>
<li>In the InsertKit desktop app, open <strong>Settings → API Keys</strong>. Keys are grouped into <strong>Transcription</strong> and <strong>AI &amp; Formatting</strong>.</li>
<li>Paste the key under <strong>Groq</strong>, then use <strong>Save</strong> and <strong>Test</strong>. Each provider row has Save / Test / Remove, and the key is masked with a show/hide toggle.</li>
<li><strong>Smart defaults</strong> kick in: adding a Groq key sets <code>whisper-large-v3</code> for speech and a Groq chat model for formatting. You can change both later.</li>
<li>On the <strong>Voice Typing</strong> page, open the <strong>Speech Engine</strong> panel and confirm the provider is Groq. A status pill shows the current provider, model and language.</li>
<li>Click into any text field (an email, Slack, a doc, a code comment), press the activation shortcut (<strong>Right Alt / AltGr</strong> by default), speak, then press it again or just stop talking. Auto-stop after silence defaults to 5 seconds.</li>
</ol>
<p>Keys sync to your InsertKit account, so you add each key once and it is there on your other devices. The Android app also supports BYOK for Groq, OpenRouter and OpenAI.</p>
<p>If you'd rather try it than read about it, here is <a href="https://insertkit.com/download">a voice typing app with bring-your-own-key support</a> for Windows, macOS and Linux.</p>
<h2>Which providers can you plug in?</h2>
<p>On the desktop app, the speech engine list includes:</p>
<table>
<thead>
<tr>
<th>Engine</th>
<th>Needs your own key?</th>
<th>Notes</th>
</tr>
</thead>
<tbody><tr>
<td>InsertKit Free</td>
<td>No</td>
<td>Hosted, daily limit shown as a % in the Usage tab</td>
</tr>
<tr>
<td>InsertKit Premium</td>
<td>No</td>
<td>Premium third-party models, uses credits</td>
</tr>
<tr>
<td>Local Offline (Whisper)</td>
<td>No</td>
<td>Runs fully on your computer, desktop only</td>
</tr>
<tr>
<td>Groq Whisper API</td>
<td>Yes</td>
<td>Groq account and limits</td>
</tr>
<tr>
<td>OpenAI</td>
<td>Yes</td>
<td>OpenAI account and limits</td>
</tr>
<tr>
<td>OpenRouter</td>
<td>Yes</td>
<td></td>
</tr>
<tr>
<td>Deepgram</td>
<td>Yes</td>
<td></td>
</tr>
<tr>
<td>AssemblyAI</td>
<td>Yes</td>
<td></td>
</tr>
<tr>
<td>ElevenLabs Scribe v2 / v1</td>
<td>Yes</td>
<td></td>
</tr>
</tbody></table>
<p>The model picker fetches the live model list from the provider and lets you search it, so you're not stuck with whatever was current when the app shipped.</p>
<p>For the formatting side (the AI that cleans up grammar and filler words), the API Keys page also takes keys for Anthropic (Claude), Google Gemini and Cloudflare Workers AI, plus a <strong>custom OpenAI-compatible provider</strong> where you set a name, base URL, key and models. LM Studio and Ollama are the usual examples of that.</p>
<h2>BYOK vs free hosted vs fully offline</h2>
<p>These three options solve different problems. A quick way to choose:</p>
<table>
<thead>
<tr>
<th>You care most about...</th>
<th>Pick</th>
</tr>
</thead>
<tbody><tr>
<td>Zero setup, just start talking</td>
<td>InsertKit Free (sign in, no key)</td>
</tr>
<tr>
<td>Audio never leaving your machine</td>
<td>Local Offline Whisper (desktop only)</td>
</tr>
<tr>
<td>Choosing the exact cloud model and paying the provider directly</td>
<td>BYOK (Groq, OpenAI, etc.)</td>
</tr>
<tr>
<td>Not hitting a hosted daily limit</td>
<td>BYOK or Local Offline</td>
</tr>
</tbody></table>
<p>A few honest tradeoffs:</p>
<ul>
<li><strong>Privacy:</strong> with BYOK, your audio still goes to a cloud provider, just one you chose. Only Local Offline mode keeps audio on your computer.</li>
<li><strong>Cost:</strong> the provider bills you (or doesn't, inside a free tier). Your dictation tool's own plan is separate.</li>
<li><strong>Speed and accuracy:</strong> these depend on the provider and model you pick, your microphone and your language. Test with your own voice before you commit.</li>
</ul>
<p>The local models download inside the app, from Tiny (<del>75 MB) up to Large v3 (</del>3 GB), plus a Bangla-specialised <strong>Bangla Light</strong> model (~460 MB).</p>
<h2>What happens after transcription</h2>
<p>Raw Whisper output is accurate, but it's still raw. Two things make dictated text usable in real apps:</p>
<ul>
<li><strong>Smart Formatting</strong> cleans punctuation and filler words ("um", "uh") and adapts style to the app you're in. Email gets a professional tone, chat stays short, and in VS Code, Cursor, IntelliJ or a terminal the Code profile writes comment/docstring style and turns spoken identifiers into camelCase or snake_case. It never translates: Bangla stays Bangla, English stays English.</li>
<li><strong>Custom Vocabulary</strong> fixes names the engine keeps getting wrong. Add hint words (product names, people, jargon) or a correction like "insert kit" → "InsertKit". Corrections run before and after formatting, so the AI can't undo them.</li>
</ul>
<p>If the formatting model is unreachable, the raw transcript is inserted anyway with a warning, so you don't lose what you said.</p>
<h2>FAQ</h2>
<p><strong>Can I use Groq Whisper for dictation in any app, not just a browser tab?</strong>
Yes, if your dictation tool inserts text system-wide. InsertKit's desktop app types at your cursor in most apps where you can type, on Windows, macOS and Linux.</p>
<p><strong>Do I need an API key to use InsertKit voice typing?</strong>
No. InsertKit Free and Premium need no key. BYOK is optional, for people who want a specific provider or model.</p>
<p><strong>Is BYOK dictation private?</strong>
It's as private as the provider you send audio to. For audio that never leaves your machine, use Local Offline Whisper on the desktop.</p>
<p><strong>Which languages work?</strong>
InsertKit voice typing supports auto-detect plus 100+ languages, including English and Bangla. What a specific provider handles well is up to that provider's model.</p>
<p><strong>How much does it cost?</strong>
InsertKit has a free tier (InsertKit Free voice with a daily limit) and a paid plan at $2.99/month. Provider charges for BYOK are billed by the provider.</p>
<p><strong>Can I switch languages without opening settings?</strong>
On the desktop app, yes. You can set two activation shortcuts for two languages (for example Right Alt for English and Ctrl+Win for Bangla), and the second shortcut can use its own provider and model.</p>
<h2>Wrap-up</h2>
<p>BYOK dictation is the middle ground between "trust whatever the app uses" and "run everything locally." If you already have a Groq or OpenAI account, plugging that key into a system-wide voice typing tool gives you a known model, your own usage dashboard, and the freedom to switch later, while the tool handles the hotkey, the cursor insertion and the clean-up.</p>
]]></content:encoded></item><item><title><![CDATA[Text Expander for Linux: How Snippet Expansion Works on X11 and Wayland (Plus a GUI Option)]]></title><description><![CDATA[A developer's guide to a text expander for Linux: X11 vs Wayland, xdotool, wtype, ydotool, a DIY snippet script, espanso, and a GUI option with sync.]]></description><link>https://alaminik.hashnode.dev/text-expander-for-linux-x11-wayland</link><guid isPermaLink="true">https://alaminik.hashnode.dev/text-expander-for-linux-x11-wayland</guid><category><![CDATA[Productivity]]></category><category><![CDATA[wayland]]></category><category><![CDATA[Tutorial]]></category><category><![CDATA[Linux]]></category><dc:creator><![CDATA[Al Amin]]></dc:creator><pubDate>Tue, 20 Oct 2026 12:44:42 GMT</pubDate><content:encoded><![CDATA[<p>Searching for a text expander for Linux usually ends in one of three places: a GitHub repo, a forum thread about Wayland, or a commercial tool that turns out not to support Linux at all. TextExpander, for example, ships desktop apps for Mac and Windows and points Linux users to its Chrome extension, which its own docs say only expands inside the browser.</p>
<p>So this post starts one level lower. If you understand the two jobs every text expander has to do, and why Wayland changes them, picking a tool (or writing your own) gets much easier. At the end I walk through the GUI setup I use, InsertKit, and where it fits next to the open-source options.</p>
<h2>What a text expander for Linux actually has to do</h2>
<p>A text expander replaces a short trigger like <code>/sig</code> with a longer saved text, in whatever app has focus. Under the hood that is two separate jobs:</p>
<ol>
<li><strong>Detect the trigger.</strong> Read keystrokes globally, keep a small buffer, and notice when the end of the buffer matches a trigger.</li>
<li><strong>Inject the text.</strong> Delete the trigger (usually with backspaces), then type or paste the replacement into the focused window.</li>
</ol>
<p>On Windows and macOS, both jobs go through OS APIs and permissions. On Linux, both depend on your display server.</p>
<h2>X11 vs. Wayland: why it matters</h2>
<p><strong>On X11</strong>, any client can observe input and synthesize events through the X server. That is why <code>xdotool type "hello"</code> just works, and why older expanders were simple to build. It is also a security weakness, since every app can see everything.</p>
<p><strong>On Wayland</strong>, clients are isolated. An app cannot read keystrokes sent to another window, and it cannot inject events into it through the display protocol. Tools work around this in a few ways:</p>
<table>
<thead>
<tr>
<th>Approach</th>
<th>Example tool</th>
<th>How it injects</th>
<th>Catch</th>
</tr>
</thead>
<tbody><tr>
<td>X server events</td>
<td><code>xdotool</code></td>
<td>Sends events to the X server</td>
<td>X11 sessions (and some XWayland apps)</td>
</tr>
<tr>
<td>Virtual keyboard protocol</td>
<td><code>wtype</code></td>
<td>Asks the compositor for a virtual keyboard</td>
<td>Only works if your compositor supports that protocol</td>
</tr>
<tr>
<td>Kernel input device</td>
<td><code>ydotool</code></td>
<td>Emulates a device via <code>/dev/uinput</code></td>
<td>Needs the <code>ydotoold</code> daemon and usually root-level access to <code>/dev/uinput</code></td>
</tr>
<tr>
<td>Clipboard + paste</td>
<td><code>wl-copy</code> + a paste keystroke</td>
<td>Puts text on the clipboard, then pastes</td>
<td>Overwrites your clipboard unless you restore it</td>
</tr>
</tbody></table>
<p>Detection is the harder half on Wayland. Reading global keystrokes generally means reading <code>/dev/input/event*</code> directly, which needs elevated permissions. espanso's Linux docs are a good, transparent example: the Wayland build needs access to <code>/dev/input/eventX</code> and <code>/dev/uinput</code>, and they recommend granting a capability with <code>setcap</code> instead of running as root.</p>
<p>First, check which session you are on:</p>
<pre><code class="language-bash">echo $XDG_SESSION_TYPE   # x11 or wayland
</code></pre>
<h2>Option 1: a 20-line DIY snippet picker</h2>
<p>If you only need a few snippets and you are happy pressing a hotkey instead of typing a trigger, you can skip detection entirely. Bind this script to a keyboard shortcut in your desktop settings:</p>
<pre><code class="language-bash">#!/usr/bin/env bash
# snip: pick a snippet from ~/snippets and type it into the focused window
dir="$HOME/snippets"
choice=$(ls "$dir" | rofi -dmenu -p snippet) || exit 0
text=$(cat "$dir/$choice")

if [ "$XDG_SESSION_TYPE" = "wayland" ]; then
  if command -v wtype &gt;/dev/null; then
    wtype "$text"
  else
    ydotool type "$text"   # requires ydotoold running
  fi
else
  xdotool type --clearmodifiers -- "$text"
fi
</code></pre>
<p>Each file in <code>~/snippets</code> is one snippet (<code>pr-template</code>, <code>bug-report</code>, <code>sig</code>). Swap <code>rofi</code> for <code>dmenu</code>, <code>wofi</code> or <code>fuzzel</code> depending on your setup.</p>
<p>It is honest, transparent and free. It also has no triggers, no variables, no sync, and you will be the one debugging it after a distro upgrade.</p>
<h2>Option 2: espanso, the file-based expander</h2>
<p>espanso is the open-source tool most Linux users land on. Its site describes it as a privacy-first, cross-platform text expander for Windows, Linux and macOS, licensed under GPL-3. Snippets live in YAML files, it has forms and shell or script extensions, and a search bar on <code>ALT+Space</code>.</p>
<p>Two things worth knowing before you install:</p>
<ul>
<li><strong>Configuration is file-based.</strong> That is great if you keep dotfiles in git. The project says a GUI is planned for the future.</li>
<li><strong>Wayland support is marked experimental</strong> in its docs, with separate X11 and Wayland builds and a few documented limitations, such as specifying non-US keyboard layouts explicitly.</li>
</ul>
<p>If you want maximum control and scripting, it is a strong pick. If you want a GUI, sync with a phone, or voice typing in the same tool, keep reading.</p>
<h2>Option 3: a GUI text expander with sync (InsertKit)</h2>
<p>InsertKit is a desktop app for Windows, macOS and Linux, with an Android app and a Chrome extension on the same account. On Linux it ships as an AppImage, <code>.deb</code> and <code>.rpm</code>. Besides snippets, it includes clipboard history and AI voice typing, which is why I use it as an espanso alternative with a GUI rather than as a pure expander.</p>
<h3>Step 1: Install and sign in</h3>
<p>Grab the package for your distro, launch it, and sign in with email or Google. The app runs in the system tray, and you can enable <strong>Start on Boot</strong> and <strong>Minimize to Tray</strong> in Settings.</p>
<h3>Step 2: Run the Linux dependency check</h3>
<p>Open <strong>Settings → General → Linux Dependencies</strong>. It checks for the helper tools InsertKit uses for typing and pasting, such as <code>xdotool</code> and <code>wtype</code>, and on Wayland its tips point to <code>wtype</code> or <code>ydotool</code>. Install whatever it flags:</p>
<pre><code class="language-bash"># Debian/Ubuntu
sudo apt install xdotool wtype
# Fedora
sudo dnf install xdotool wtype
</code></pre>
<p>If you are on Wayland, test expansion in a few apps you use daily (a terminal, your browser, your editor) before relying on it, for the same compositor reasons described above.</p>
<h3>Step 3: Create a snippet in the GUI</h3>
<p>Go to <strong>Snippets → Add Snippet</strong>. Set a trigger like <code>/sig</code>, a title, and the content. When the end of what you type matches a trigger, InsertKit deletes the trigger and pastes the snippet in its place. Type just <code>/</code> and an autocomplete popup appears at your cursor, showing matching triggers, titles and a short preview. Arrow keys move, Tab or Enter inserts, Esc closes.</p>
<h3>Step 4: Dynamic snippets for developer boilerplate</h3>
<p>This is where a GUI beats a hand-rolled script. Turn on <strong>Dynamic</strong> in the snippet dialog and add fields (text, dropdown, date, time, date and time, or your name). A bug report template might look like this:</p>
<pre><code class="language-text">**Component:** {{component}}
**Severity:** {{severity}}
**Reported:** {{date}}

### Steps to reproduce
1.

### Expected

### Actual
</code></pre>
<p>Make <code>severity</code> a dropdown with <code>low, medium, high</code>, and <code>component</code> a text field. When you type <code>/bug</code>, a small form pops up; Enter inserts the filled-in text. Built-in variables like <code>{{date}}</code>, <code>{{time}}</code> and <code>{{myName}}</code> follow your locale and timezone.</p>
<h3>Step 5: Variations for templates with several shapes</h3>
<p>For PR descriptions, turn on <strong>Snippet variations</strong> instead. One trigger, <code>/pr</code>, can hold "Feature", "Bugfix" and "Chore" templates. Typing it opens a <strong>Choose variation</strong> picker with numbered items and a counter, so you never maintain <code>/pr-feat</code>, <code>/pr-fix</code> and <code>/pr-chore</code> separately. (Variations and Dynamic cannot be on for the same snippet, so pick one per snippet.)</p>
<h3>Step 6: Pause snippets in the terminal</h3>
<p>Vim and shell users will hit this early: a slash followed by a word you meant literally. Press <strong>F4</strong> to turn the whole snippet system off or on. A small toast confirms "Snippets disabled" or "Snippets enabled". The key is configurable in <strong>Settings → Snippets</strong>.</p>
<h3>Step 7: Clipboard history and voice, while you are here</h3>
<ul>
<li><strong>Ctrl+Shift+Z</strong> opens a floating clipboard popup with Clipboard, Snippets and Favorites tabs. Click an item to copy and insert it into the app you were using.</li>
<li><strong>Right Alt</strong> (configurable) starts voice typing at your cursor. In a code editor or terminal, the Code formatting profile turns spoken identifiers into camelCase or snake_case. On desktop you can also run a <strong>Local Offline (Whisper)</strong> model, so audio stays on your machine. Voice typing covers 100+ languages.</li>
</ul>
<h2>Comparison: DIY script vs. espanso vs. InsertKit on Linux</h2>
<table>
<thead>
<tr>
<th></th>
<th>DIY script</th>
<th>espanso</th>
<th>InsertKit</th>
</tr>
</thead>
<tbody><tr>
<td>Price</td>
<td>Free</td>
<td>Free, GPL-3</td>
<td>Free plan; paid plan $2.99/month</td>
</tr>
<tr>
<td>Config</td>
<td>Files you write</td>
<td>YAML files (GUI planned)</td>
<td>GUI app, synced to an account</td>
</tr>
<tr>
<td>Trigger detection</td>
<td>None (hotkey + picker)</td>
<td>Yes</td>
<td>Yes, plus autocomplete popup</td>
</tr>
<tr>
<td>Wayland</td>
<td><code>wtype</code> or <code>ydotool</code></td>
<td>Experimental, separate build</td>
<td>Dependency check points to <code>wtype</code> / <code>ydotool</code>; test on your compositor</td>
</tr>
<tr>
<td>Forms / variables</td>
<td>DIY</td>
<td>Forms, shell and script extensions</td>
<td>Dynamic fields, built-in date/time/name variables</td>
</tr>
<tr>
<td>Voice typing</td>
<td>No</td>
<td>Not a feature</td>
<td>Yes, including local Whisper</td>
</tr>
<tr>
<td>Other platforms</td>
<td>Linux only</td>
<td>Windows, macOS</td>
<td>Windows, macOS, Android, Chrome</td>
</tr>
</tbody></table>
<p>espanso wins on openness and scripting. The DIY script wins on simplicity. InsertKit fits if you want a GUI, snippet variations, synced clipboard history, the same snippets on your phone, and dictation in the same tool.</p>
<h2>FAQ</h2>
<h3>What is the easiest text expander for Linux?</h3>
<p>If you want a GUI, a desktop app with a snippet editor is the easiest start. If you are comfortable with YAML, espanso is free and well documented.</p>
<h3>Does a text expander work on Wayland?</h3>
<p>It can, but detection and injection need different mechanisms than on X11, so support varies by tool and compositor. Check <code>$XDG_SESSION_TYPE</code>, follow the tool's Wayland instructions, and test in the apps you use most.</p>
<h3>Is there a TextExpander alternative for Linux?</h3>
<p>TextExpander does not offer a Linux desktop app; its docs suggest the Chrome extension, which expands only inside Chrome. Native options include espanso and InsertKit, both of which run on Linux desktops.</p>
<h3>Is there an espanso alternative with a GUI?</h3>
<p>InsertKit manages snippets in a desktop GUI and syncs them to Android and Chrome. If open source is a requirement for you, espanso remains the natural pick.</p>
<h3>Can I keep using snippets in vim or a terminal?</h3>
<p>Yes, but you will want a quick way to pause them. In InsertKit, F4 toggles all snippets; in a DIY setup, a hotkey-only picker avoids accidental triggers entirely.</p>
<h2>Wrapping up</h2>
<p>The right text expander for Linux depends less on features than on your session type and how you like to configure things. Check X11 vs. Wayland first, decide whether you want triggers or a hotkey picker, then choose between files and a GUI.</p>
<p>If you want to try the GUI route, the AppImage, <code>.deb</code> and <code>.rpm</code> builds are on the download page for <a href="https://insertkit.com/download">a GUI text expander for Linux</a>.</p>
]]></content:encoded></item></channel></rss>