Tag: Emacs

Obscure Emacs Package: ssh-config-mode

Wednesday, Oct 1, 2025

There’s this cool blog-o-sphere Emacs party going on, with September’s theme of everything about obscure packages. And woops, I’m a day late to the party, so here goes nothing. The idea is to post a weird package that you use but is sort of obscure! M-x winny/visit-configuration RET and I’ve selected uhhh… ssh-config-mode ssh-config-mode Syntax highlighting for your SSH configs, known hosts, and authorized keys files. Nuff said. I have the following line in my Emacs configuration.

Continue reading…

10PRINT inspired "Snowcrash" in Emacs

Saturday, Apr 19, 2025

The sky above the port was the color of television, turned to a dead channel. — Opening paragraph from William Gibson’s Neuromancer. So I thought to myself, why not write a screensaver for Emacs? Enter snowcrash.el. It’s not on MELPA or anything, but it does live on GitHub within my Emacs configuration repository. M-x snowcrash RET looks like this: It’s fun to look at or leave running as a screensaver!

Continue reading…

Emacs: Edit as root using sudo-edit

Friday, Apr 11, 2025

Figure 1: sudo plus emacs Emacs offers TRAMP as a way to edit files over ssh or as a different user. Combine with sudo-edit for easy superuser edits. VSCode has a feature reminiscent of TRAMP called Remote Development using SSH. At the time, I didn’t know of M-x sudo-edit so I wrote my own implementation. It sucked, didn’t work on chained TRAMP connections (e.g. ssh then edit as root on the remote host).

Continue reading…

Shellcheck and Emacs

Sunday, Sep 8, 2024

Previously I introduced the reader to ShellCheck. In this post I detail how I use Flycheck in Emacs and offer an Emacs function to automatically suppress Shellcheck errors at the current line. I’m an avid Emacs user and it follows that I’ve set up editor customization to exude the most from ShellCheck. If you, dear reader, are not an Emacs user, I cannot help you! Please, for the love of shell scripts, ensure ShellCheck works within your preferred text editor, lest you wish to ship edgecased buggy scripts!

Continue reading…

Multiple arguments in shebang

Wednesday, Jan 10, 2024

Figure 1: Jamian · CC BY 3.0 Deed (link) A frequent quip of the unix-beard is shebangs cannot contain multiple command-line arguments. Let’s break it down and see where this assumption no longer holds true. What is a Shebang? The shebang is the line at the beginning scripts such as Python and Shell scripts that instructs the OS how to execute the script. Looks something like #!/bin/sh or #!/usr/bin/env python.

Continue reading…

Migrating from Emacs 26 to Emacs 27 on Gentoo

Sunday, Nov 28, 2021

Figure 1: Behold! Emacs 27! When upgrading to Emacs 27 there were quite a few weird things I had to address. My Emacs is installed via Gentoo Portage. The USE flags I have set (to enable/disable features at build time) essentially configure my Emacs to be like Lucid Emacs builds. Here’s the USE flags: Xaw3d acl alsa athena cairo dbus dynamic-loading gif gmp gui imagemagick inotify jpeg lcms libxml2 png source ssl svg threads tiff toolkit-scroll-bars xft xpm zlib -aqua -games -gconf -gfile -gpm -gsettings -gtk -gzip-el -harfbuzz -json -kerberos -livecd -m17n-lib -mailutils -motif -selinux -sound -systemd -wide-int -xwidgets Make note that cairo support is enabled.

Continue reading…

Track down basic Emacs bugs & hangs

Friday, Nov 1, 2019

I ran into a hang today with only ivy enabled and nothing else configured or installed. The behavior was such that after I typed a hostname with a TLD (such as not.existant.com1), then typed C-x d to visit a directory or C-x C-f to find a file, Emacs would hang. My mouse would turn into a pin-wheel. My only recourse was to send the ‘quit’ command via C-g to cancel the operation.

Continue reading…