james@kartar : ~ / 2026 / 6 / aliases-i-have-known-2026
Overview

Aliases I Have Known, 2026 Edition

6 min read

Aliases I Have Known, 2026 Edition

About five years ago I wrote a post called Aliases I have known, sharing the shell aliases I’d carted around laptops for years. I still cart them around. But I went back and read that post recently and almost none of the commands underneath the aliases are the same any more. The shortcuts survived; the things they point at got replaced.

Two changes did most of that. Half the commands I use every day are now Rust rewrites of tools I’d been typing since the late nineties, and I started using jj in addition to git. There’s a third change too, which is that I don’t actually write these aliases by hand any more. More on that at the end.

The coreutils got rewritten while I wasn’t looking

At some point I looked down and realized most of my common commands had been quietly swapped out for faster, friendlier versions, most of them written in Rust. So a chunk of my aliases now exist just to point the old name at the new tool.

Terminal window
alias cat='bat -p --paging=never'
alias ls='eza'
alias l='eza -l'
alias la='eza -la'
alias lt='eza --tree'
alias tree='eza --tree'
alias du='dust'
alias dud='dust -d 1'
alias ps='procs'
alias pgrep='procs --pgrep'
alias top='btm'
alias htop='btm'
alias ping='prettyping --nolegend'
alias cloc='tokei'

So cat is bat, ls is eza, du is dust, ps is procs, top and htop are bottom, ping is prettyping, and counting lines of code is tokei. The muscle memory is intact, because my aging memory ain’t much use anymore, and the output is nicer.

There is one thing worth knowing before you alias cat and ls over the real commands. Aliases only apply in your interactive shell. A script with a #!/bin/bash shebang doesn’t load your .zshrc, so it gets the genuine cat, not bat, and won’t break in the ways you might fear. And if you want the real command in your interactive shell anyway, you can prefix it with a backslash (\cat) or use command cat. Once upon a time I knew that but it’d clearly being moved into attic storage because it only came back to my forebrain recently.

I stopped arguing with git and started arguing with jj

The biggest change is that I switched version control. I moved most of my work to Jujutsu, or jj, which sits on top of a Git repository but gives you a much saner model to work in. That meant a whole new family of aliases.

Terminal window
alias js='jj status'
alias jl='jj log'
alias jd='jj describe -m'
alias jc='jj commit -m'
alias jdi='jj diff'
alias je='jj edit'
alias jn='jj new'
alias jnm='jj new main'
alias jf='jj git fetch'
alias jr='jj rebase -d main'
alias jsq='jj squash'
alias jp='jj git push'

Longtime readers, both of you, might remember that the original post ended with two of my favorites: nah, which threw away my uncommitted changes, and hellnah, which reached for git reset --hard. They’re still there. But they’ve had children.

Terminal window
alias jnah='jj restore'
alias jhellnah='jj abandon @'

jnah puts the working copy back the way it was, and jhellnah abandons the current change entirely, which is the jj way of admitting the last hour was a mistake. I find it reassuring that no matter which version control system I use, I need a one-word alias for “undo my poor decisions.”

I also have a few functions for the operations that don’t fit on one line, the most-used being a push helper:

Terminal window
jpush() {
if [ -z "$1" ]; then
echo "Usage: jpush \"commit message\""
return 1
fi
jj commit -m "$1" && jj tug && jj git push
}

That commits, drags my bookmark forward to the new change, and pushes, which is three commands I’d otherwise type in the same order every time.

I haven’t deleted the old git aliases, mind you. gs, gca, gpo, glog, and the rest are all still there, because not every repository I touch is a jj repository.

Still monumentally fat-fingered

In the original post I confessed to an alias for sl, because I type ls wrong often enough that it was easier to alias the typo than to fix my hands. Five years of practice have not helped. These days the typos I’ve given up fighting are git ones:

Terminal window
alias got='git'
alias gti='git'

There is no improving past a certain point. You just alias your way around yourself.

One new alias

I’ll let this one sit here without much comment:

Terminal window
alias claude='claude --dangerously-skip-permissions'

I have made my peace with it. My future self may feel differently.

The aliases aren’t where the action is any more

This is that third change I promised. A lot of what I used to solve with an alias is now solved by a tool that hooks into the shell instead.

In 2021 I had a handful of aliases for jumping between directories, and I assumed that collection would grow over time. It didn’t. The basics are still there, .., ..., and s for ~/src, but I never added more, because zoxide now learns the directories I visit and lets me z to any of them by a fragment of their name. Back then I also had a plain h alias for history and leaned hard on Ctrl-R; atuin has since taken that over and keeps my history in a searchable database that follows me between machines. My prompt is starship, runtime versions are handled by mise, per-directory environments by direnv, and when I fat-finger a whole command rather than just git, pay-respects offers to fix it. I still keep a couple of aliases that wrap these, like a yy function around the yazi file manager that drops me in whatever directory I browsed to, but the heavy lifting has moved out of the alias file.

Which brings me to the last change. The original post spent several paragraphs explaining .bashrc versus .bash_profile, where to put your aliases, and how to make sure they got loaded. I don’t manage any of that by hand any more. My whole machine is configured with Nix, so these aliases are declared in a configuration file and the .zshrc is generated from it. When I want a new one, I add it to the Nix config and rebuild:

Terminal window
alias update='cd ~/.config/nixpkgs && nix flake update && sudo darwin-rebuild switch --flake .#mbp --show-trace'

The file full of alias lines still exists, it’s just an output now rather than something I edit. Which is either progress or an elaborate way of avoiding learning where .zshrc lives. I genuinely can’t tell.

Until the next one

The original post promised a follow-up on functions, which I then published only five years later. By that schedule I’m due to revisit this one somewhere around 2031, by which point I assume all of these tools will have been rewritten again, possibly in a language that doesn’t exist yet. The aliases, though, will be exactly the same two letters. Unless, we’re reduced to hunting radioactive squirrels in Prospect Park instead of software engineering. Which, frankly, seems plausible right now.