05 April 2023 Flat Habits 1.1.4 released Flat Habits 1.1.4 is now available on the App Store. Flat Habits is a habit tracker that’s mindful of your time, data, and privacy. It's a simple but effective iOS app. If you care about how your data is stored, Flat Habits i … | Continue reading
21 March 2023 A ChatGPT Emacs shell I had been meaning to give ChatGPT a go. Preferably from Emacs. As an eshell fan, ChatGPT just seemed like the perfect fit for a shell interface sorts. With that in mind, I set out to wire ChatGPT out with Emacs's general command interpreter … | Continue reading
04 March 2023 *scratch* a new minimal org mode scratch area for iOS While we already have lots of note-taking apps on iOS, I wanted a minimal *scratch* area (à la Emacs), so I built one. What's the use-case? You're on the go. Someone's telling you directions, or a phon … | Continue reading
29 January 2023 Chicken Karaage recipe Huge fan of Chicken Karaage, but never really made it at home until recently. Dice the chicken 350 grams boneless chicken thighs Dice the chicken up. Marinade for 30 mins 1 tablespoon soy sauce (Kikkoman or simil … | Continue reading
10 January 2023 Emacs: org-present in style I had been meaning to check out David Wilson's System Crafters post detailing his presentations style achieved with the help of org-present and his own customizations. If you're looking for ways to present from Emacs itself, David's p … | Continue reading
08 January 2023 Emacs: insert and render SF symbols About a week ago, I added an Emacs function to insert SF symbol names. This is specially useful for SwiftUI. I didn't bother too much with inserting symbols themselves since I hadn't figured out a way to render them for all bu … | Continue reading
31 December 2022 Emacs: Macro me some SF Symbols For inserting SF Symbols in SwiftUI, I typically rely on Apple's SF Symbols app to browse the symbols's catalog. Once I find a symbol I'm happy with, I copy its name and paste it into my Swift source. This works fairly well. Wi … | Continue reading
18 December 2022 Emacs: ffmpeg and macOS aliasing commands On a recent mastodon post, Chris Spackman mentioned he uses Emacs to save ffmpeg commands he's figured out for later usage. Emacs is great for this kind of thing. I've tried different approaches over time and eventually … | Continue reading
12 December 2022 Emacs: Context-aware yasnippets Back in 2020, I wrote a semi-automatic yasnippet to generate Swift initializers. I say semi-automatic because it could have been a little smarter. While it helped generate some of the code, what I really wanted was full context-a … | Continue reading
12 November 2022 Emacs: quickly killing processes Every so often, I need to kill the odd unresponsive process. While I really like proced (check out Mickey Petersen's article), I somehow find myself using macOS's Activity Monitor to this purpose. Kinda odd, considering I prefer … | Continue reading
06 November 2022 Hey Emacs, change the default macOS app for… A few weeks ago, I added an "open with" command to dwim-shell-commands.el. It's pretty handy for opening files using an external app (ie. not Emacs) other than the default macOS one. dwim-shell-commands-macos-open- … | Continue reading
02 November 2022 Hey Emacs, where did I take that photo? I was recently browsing through an old archive of holiday photos (from dired of course). I wanted to know where the photo was taken, which got me interested in extracting Exif metadata. Luckily the exiftool command line … | Continue reading
23 October 2022 Emacs: A welcoming experiment The *scratch* buffer is the first thing I see when I launch an Emacs session. Coupled with persistent-scratch, it's served me well over the years. I gotta say though, my scratch buffer accumulates random bits and often becomes a lit … | Continue reading
14 October 2022 Emacs: Open with macOS app On a recent Reddit comment, tdstoff7 asked if I had considered writing an "Open with" DWIM shell command for those times one would like to open a file externally using an app other than the default. I hadn't, but nice idea. Take imag … | Continue reading
12 October 2022 Improving on Emacs macOS sharing A quick follow-up to Emacs: macOS sharing (DWIM style)… Though functional, the implementation had a couple of drawbacks. Tohiko noticed fullscreen wasn't working at all while Calvin proposed enumeration for tighter Emacs integr … | Continue reading
12 October 2022 Emacs: macOS sharing (DWIM style) UPDATE: See an improved implementation here. A few days ago, I wrote dwim-shell-commands-macos-reveal-in-finder. While I've written a bunch of other dwim-shell-commands, what set this case apart was the use of Swift to glue an … | Continue reading
09 October 2022 Emacs: Reveal in macOS Finder (DWIM style) Just the other day, Graham Voysey filed an escaping bug against dwim-shell-command. Once he verified the the fix, he also posted two uses of dwim-shell-command-on-marked-files. I've made some small tweaks, but here's th … | Continue reading
01 October 2022 Plain Org v1.5 released If you haven't heard of Plain Org, it gives you access to org files on iOS while away from your beloved Emacs. Hadn't had time to post, but v1.5 has been available on the App Store for a couple of weeks now. The update is mostly a bugfi … | Continue reading
01 October 2022 dwim-shell-command usages: pdftotext and scp dwim-shell-command is a little Emacs package I wrote to enable crafting more reusable shell commands. I intended to use it as an async-shell-command alternative (and I do these days). The more surprising win was bring … | Continue reading
Article URL: https://xenodium.com/rm-important-txt-oh-sht/ Comments URL: https://news.ycombinator.com/item?id=32880961 Points: 69 # Comments: 78 | Continue reading
17 September 2022 $ rm Important.txt (uh oh!) Setting Emacs up to use your system trash can potentially save your bacon if you mistakenly delete a file, say from dired. Unsurprisingly, the trash safety net also extends to other Emacs areas. For example, discarding files from … | Continue reading
11 September 2022 Cycling through window layouts (revisited) Last year, I wrote a little script to cycle through window layouts via Hammerspoon. The cycling set I chose didn't stick, so here's another go. function reframeFocusedWindow() local win = hs.window.focusedWin … | Continue reading
18 August 2022 dwim-shell-command with template prompts Somewhat recently, I wanted to quickly create an empty/transparent png file. ImageMagick's convert has you covered here. Say you want a transparent 200x400 image, you can get it with: convert -verbose -size 200x400 xc:no … | Continue reading
14 August 2022 Seamless command-line utils Just the other day, I received a restaurant menu split into a handful of image files. I wanted to forward the menu to others but figured I should probably send it as a single file. ImageMagick's convert command-line utility works gre … | Continue reading
03 August 2022 Emacs freebie: macOS emoji picker I recently ran a little experiment to bring macOS's long-press-accents-like behavior to Emacs. What I forgot to mention is that macOS's character viewer just works from our beloved editor. If you have a newer MacBook model, you … | Continue reading
01 August 2022 dwim-shell-command video streams I continue hunting for use-cases I can migrate to dwim-shell-command… After adding clipboard support (via ) I found one more. Copy URL from browser. Invoke dwim-shell-commands-mpv-stream-clipboard-url. Enjoy picture in picture f … | Continue reading
30 July 2022 An accentuated Emacs experiment (à la macOS) macOS has a wonderful input mechanism where you press and hold a key on your keyboard to display the accent menu. It's easy to internalize: long press "a" if you want to input "á". On Emacs, C-x 8 ' a would be the … | Continue reading
28 July 2022 dwim-shell-command improvements Added a few improvements to dwim-shell-command. Dired region In DWIM style, if you happen to have a dired region selected, use region files instead. There's no need to explicitly mark them. Clipboard (kill-ring) replaceme … | Continue reading
24 July 2022 dwim-shell-command on Melpa Figure 1: gets replaced by a clipboard (kill ring) URL My pull request to add dwim-shell-command to melpa has been merged. Soon, you'll be able to install directly from Milkypostman’s Emacs Lisp Package Archive. dwim-shell-comman … | Continue reading
16 July 2022 A lifehack for your shell I'm a fan of the unzip command line utility that ships with macOS. I give it a .zip file and it unzips it for me. No flags or arguments to remember (for my typical usages anyway). Most importantly, I've fully internalized the unzip com … | Continue reading
13 July 2022 Emacs zones to lift you up As I prune my Emacs config off, I came across a forgotten bit of elisp I wrote about 6 years ago. While it's not going to power up your Emacs fu, it may lift your spirits, or maybe just aid discovery of new words. You see, I had for … | Continue reading
10 July 2022 Emacs: DWIM shell command (multi-language) UPDATE: dwim-shell-command is now available on melpa. I keep on goofying around with dwim-shell-command and it's sibling dwim-shell-command-on-marked-files from dwim-shell-command.el. In addition to defaulting to z … | Continue reading
09 July 2022 Emacs: Password-protect current pdf (revisited) UPDATE: dwim-shell-command is now available on melpa. With a recent look at writing DWIM shell commands, I've been revisiting my custom Emacs functions invoking command line utilities. Take this post, for exam … | Continue reading
09 July 2022 png to icns (Emacs DWIM style) UPDATE: dwim-shell-command is now available on melpa. Since writing a DWIM version of the shell-command, I've been having a little fun revisiting command line utilities I sometimes invoke from my beloved editor. In this instance … | Continue reading
07 July 2022 Emacs DWIM shell-command UPDATE: dwim-shell-command is now available on melpa. I've talked about DWIM before, where I bend Emacs to help me do what I mean. Emacs is also great for wrapping command-line one-liners with elisp, so I can quickly invoke commands witho … | Continue reading
02 June 2022 Emacs: Password-protect current pdf UPDATE: Check out Password-protect current pdf (revisted) for a simpler version. Every so often, I need to password-protect a pdf. On macOS, Preview has a simple solution, but I figured there must be a command line utility to m … | Continue reading