Jack Baty

Director of Unspecified Services

Hiding File Permissions in Dired

2022-07-31

Dired mode in Emacs is fantastic, but one little thing that annoyed me was that the directory listings show file ownership and permissions, taking up space with information I almost never care about. I started down a rabbit hole of figuring out how to hide those columns. I spent wasted an hour on my way to discovering that, of course, there’s a built-in way to do it: dired-hide-details-mode.

Continue reading

C-x C-c

2022-06-29

I rage-quit Emacs this morning. By that, I don’t mean that I hit C-x C-c really hard, although I did do that. I mean I stopped using Emacs.

Continue reading

Publishing portions of my Org-roam database

2022-03-27 Software Jack
I’m trying something new. I’ve become a pretty heavy user of Org-roam for personal notes. I put nearly everything there now; technical notes, contact information, project notes, vendor info, etc. These notes are all nicely linked and backlinked and live in my main ~/org directory so I can easily find things right within Emacs. A portion of these notes might be useful to other people. So I’m exporting the shareable notes from Org-roam as Hugo-compatible Markdown files. Continue reading

Aligning comments in Emacs

2022-03-25 Software Jack
I want my per-line code comments to line up nicely, so I’ll often add a bunch of spaces by hand to make things just so. I realized that, being Emacs, there must be an easier way to handle this. Of course there is. Two minutes of searching revealed a short bit of lisp that does the job nicely: ;; Align comments in marked region ;; Via https://stackoverflow.com/a/20278032 (defun jab/align-comments (beginning end) "Align comments within marked region. Continue reading

Configuring the org-download save directory

2022-03-19 Software Jack
When I drag and drop an image into Emacs, I want the attached file to end up in ./img/YYYY/. This is how I tried configuring org-download in my setup (I use Doom Emacs): (setq org-download-method 'directory org-download-image-dir (concat "img/" (format-time-string "%Y") "/") org-download-image-org-width 600 org-download-heading-lvl 1) For some reason, org-download-method was being reset from 'directory to 'attach after loading, and this broke things. I thought maybe I needed to set the variables after org-download was loaded, so I did this: Continue reading

Posting from Emacs to WordPress using Org2Blog

2022-03-18 Misc Jack
I’ve settled on WordPress for this blog. (“settled” is a fluid word for me, but let’s assume I mean it for now). However, I prefer to do most of my writing in Emacs and Org mode. To help with this, I’ve configured org2blog and I’m writing this post with it. I’m using org2blog pretty much right out of the box. Just a single blog configuration with the following tweaks: <div class="org-src-container"><pre id="nil" class="src src-emacs-lisp"><span style="color: #4078f2;">(</span><span style="color: #e45649;">setq</span> <span style="color: #6a1868;">org2blog/wp-track-posts</span> <span style="color: #a626a4;">(</span><span style="color: #b751b6;">list</span> <span style="color: #50a14f;">"~/org/baty. Continue reading

Doom Emacs from scratch

2021-03-10 Misc Jack
A week ago I decided to cancel Doom Emacs and go back to building Emacs from Scratch, and once again I was reminded what a terrible idea that is. Seriously, stock Emacs, even with a leg up from Nano Emacs, gets so many things “wrong” that I could spend the rest of my life fixing things and still wanting more. I thought building from scratch would help me avoid Configuration Fatigue. Continue reading