Thinking less to do more: Dev Tool Time with ThePrimeagen
As a popular Twitch streamer and Vim enthusiast, ThePrimeagen is known for his fast-paced tmux and Neovim-focused workflow, shifting quickly between windows, buffers, and code chunks. When he joined us for Dev Tool Time on October 27, 2021, he shared his approach to reducing cognitive overhead in his dev workflow and showed how his custom configurations make it easier to think less and do more.
You can watch the recording of this episode at the bottom of this blog post, but first let’s check out ThePrimeagen’s desk setup:
ThePrimeagen's desk setup is doubly determined by his work as a developer and his position as a streamer. While he prefers coding on a single, relatively normal-sized monitor, he has two on his desk. The Acer Predator is his primary monitor, which is attached to his System76 laptop running Ubuntu. The second monitor is hooked up to a Windows machine that runs his Twitch stream, since some of his hardware, such as the Streamdeck and GoXLR, don't yet have Linux drivers. Kinesis keyboards, notably the Advantage 2 take up a chunk of desk space.
As part of his drive to make typing more efficient, ThePrimeagen uses the Dvorak keyboard layout, which optimizes for alternating keypresses between two hands and focuses on the home row among other efficiencies.
Configuration and cognitive overhead
ThePrimeagen is known for his Vim mastery, which he demonstrates on stream with speed and smoothness. His approach isn't driven purely by speed or efficiency, though. As much as possible, ThePrimeagen tries to reduce thinking about steps he shouldn't have to think about, such as which keybinding will take him to the window with his terminal (Mod+3) or to his always-open GIMP window (Mod+6).
By consistently organizing keybindings for actions, and building muscle memory, ThePrimeagen cuts down on the small pauses needed to figure out how to perform the next intended action. This approach carries through to his main text editor, Neovim, for which he, and his co-contributors, built Harpoon, a plugin for file and terminal navigation.
Configuration is personal, though, and while ThePrimeagen's dotfiles are a source of inspiration for many, his own keybindings and preferences are optimized for him. Others might need to take different approaches, or fine-tune the same combination of core apps (i3, tmux, and Neovim) differently. Following ThePrimeagen's approach is about finding problematically complex aspects of your current setup, even if that complexity comes from seemingly ergonomic approaches like mnemonics, and simplifying in a way that works with your own mental model and habits.
git worktree so you don't have to
Reducing cognitive overhead is as much about taking advantage of existing tools and workflows as it is extensive configuration. One of ThePrimagen's examples of this is his relatively recent switch to using Git worktrees, which allow you to concurrently checkout multiple branches of a repository. Rather than going through the steps of stashing changes, switching branches, and later on figuring out what to pop, worktrees are an interface to a simpler model of navigating branches.
Even milliseconds matter (to ThePrimeagen)
In his VimConf 2020 talk, "Vim Speed and Excellence", ThePrimeagen examines the ways that using particular commands in Vim can be faster or slower for himself and, by extension, for other individuals. It comes down to milliseconds of gain, but that's worth it for someone who is perpetually evolving a development environment for speed, efficiency, and unobtrusiveness. ThePrimeagen thinks a lot about his setup sometimes, so that the rest of the time, when he's using it, he doesn't really have to think about it at all. Instead, he just codes.
- AKG K712 headphones
- Acer Predator monitor
- Audio Technica microphones
- Dvorak keyboard layout
- Elgato capture card
- GNU Stow
- Git worktrees
- Harpoon Neovim plugin
- I3 tiling window manager
- Kinesis Advantage keyboard
- System76 laptop
- Telescope Neovim plugin
- Tldr CLI tool
- Vim Speed and Excellence - the Primeagen's VimConf 2020 talk
Select videos from the Primeagen
Watch the recording
Check out the recording of the episode below, and be sure to sign up for upcoming events!