⏻
HELGE SVERREAll-stack Developer
Bergen, Norway • v13.0
est. 2012  |  197 repos  |  12.8k+ contributions
Tools  |   Theme:
How Much Did My One-Letter Aliases Actually Save Me?
August 26, 2026

I have three one-letter aliases in my .zshrc:

alias j='just'
alias s='stree .'
alias z='zed .'

j runs just, s opens the current directory in Sourcetree, and z opens it in Zed. I use them all day, and I got curious how many characters they've saved me. So I grepped my .zsh_history from January to August 2026 (about 38.9k commands) and counted each alias against its spelled-out version.

My shell history

AliasExpands toTimes usedChars saved/useTotal chars saved
jjust2,62137,863
sstree .2,364614,184
zzed .1254500
Total5,11022,547
j → just2,621
s → stree .2,364
z → zed .125

s wins even though j gets used more, because it replaces six characters instead of three.

I still typed just in full 631 times, mostly from before the alias became muscle memory. zed shows up in full 88 times, usually with a file argument like zed foo.rs, which z doesn't cover. stree in full: zero times.

22,547 characters is roughly four printed pages. At about 4 characters per token, it's around 5,600 tokens.

Agents don't use them

I also wanted to know if Claude Code, Codex and the other agent CLIs ever use these aliases. I checked with AgentsView, which keeps a local index of every AI CLI session I've run, about 880k messages in total. Out of 30k+ Bash tool calls, one used j, s or z.

That makes sense. Agent shells run non-interactively, so .zshrc never gets loaded and the aliases don't exist. The agent types just build in full every time.

The only time an agent sees s is when I run it myself with ! s inside Claude Code. It has no idea what that means, and since v2.1.186 it replies to it anyway. I had Claude dig into why.

If they did

Out of curiosity I counted how often agents ran the full commands, across Claude Code, Codex, Amp, Gemini, Pi and Kimi:

Full commandAliasTimes run by agentsChars saved/useNaive chars saved
justj1,71635,148
zedz244
strees060
Total1,7185,152
just → j1,716
zed → z2
stree → s0

Nearly all of it is just: just test, just format, just build. zed and stree open GUI apps, so agents have little reason to run them. Claude Code accounts for 1,020 of the just calls and Amp for 434, with the rest spread over Codex, Pi, Kimi and Gemini.

5,152 characters works out to about 1,290 tokens across every agent session I've ever run, so aliases wouldn't do much for them anyway.




<!-- generated with nested tables and zero regrets -->