I finally fixed the images in the blog; I had never really dug into
where Hugo was storing them, so all my references were broken. I
finally did some searching around, gained some understanding of what's
going on, and fixed things (for the moment, all images are in the
static/ directory, however I may eventually move them to assets/
in order to be able to do things like automatically generate smaller
versions).
As part of fixing things, I needed to edit all the image links in all of the articles in the blog that had one. Some emacs packages I use allow this to be done very efficiently, but I honestly hadn't taken the time to learn them well enough to take advantage of them.
This time, though, rather than just doing things manually, I decided
to use this as a jumping-off point for becoming more
familiar—specifically, in this case, with consult and embark,
both packages from Daniel Mendler.
Now I do actually use consult often, but only as a drop-in for
certain bits of default functionality:
;; Better completing-read implementation
(use-package consult
:after
(project)
:bind
(([remap goto-line] . consult-goto-line)
([remap switch-to-buffer] . consult-buffer)
([remap yank-pop] . consult-yank-pop))
:config
(advice-add #'project-find-regexp :override #'consult-ripgrep))
The one I use the most by far is consult-ripgrep, which will search
through files in the current project and allow me to browse through
the results interactively. This made it easy enough to find the
links I needed to change, but then I needed to change them.
Rather than having this functionality built into consult, embark
is configured so that any time it is invoked (it's bound to C-.), it
will present me with a list of possible actions to take on the
structure(s) it can discern at the current position. In the consult
list, this means it can, among other things, export the results to a
*grep* buffer, where it will display the searched-for fragments.
From there I can invoke wgrep to make those fragments editable,
change them all, and save the changes.
It's a little funny that, as I find myself contemplating retirement (17 calendar days, 10 working days!), I'm actually really excited about the prospect of picking up and becoming conversant with even more bits of Emacs functionality. The last time I really set out to try and build my Emacs knowledge was, funny enough, in 2012, shortly before I started was has become my last full-time job.