HELGE SVERREAll-stack Developer
Bergen, Norwayv13.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 shell aliases I use dozens of times a day:

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

j runs just. s opens the current directory in Sourcetree. z opens it in Zed. I wanted to know how much they've actually saved me, so I grepped 7 months of .zsh_history (Jan-Aug 2026, ~38.9k commands) for exact alias invocations versus the spelled-out equivalents.

The numbers

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

I typed just in full 631 times (old habit, before the alias stuck), zed in full 88 times (usually with a specific file, like zed foo.rs, which the alias can't help with), and stree in full exactly zero times. s fully replaced it.

22,547 characters is about 4 printed pages of text over a few thousand terminal commands. At roughly 4 characters per token, that's about 5,600 tokens.

Somewhere, a .zshrc is crying

I checked whether Claude Code, Codex, or any of the other agent CLIs I use ever run j, s, or z themselves. I pulled this from AgentsView's local session index: about 880k messages across every AI CLI I've used. The answer is essentially never: one hit, in 30k+ Bash tool calls. Agent shells run non-interactively, so .zshrc never gets sourced. The agent has no idea j means anything, so it always spells out just build or git status in full.

So the savings above are entirely mine. My aliases only pay off for the human typing at the prompt.

Totally hypothetical token savings

I went back through the same AgentsView index, every Bash-style tool call across every AI CLI I use (Claude Code, Codex, Amp, Gemini, Pi, Kimi), and counted how many times an agent ran the full command (just ..., zed ..., stree ...) that a 1-character alias would have replaced.

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

just is the one they actually run a lot: mostly just test, just format, just build. zed and stree open GUI apps, so agents have almost no reason to touch them. Most of the hits come from Claude Code (1,020) and Amp (434), with Codex, Pi, Kimi, and Gemini splitting the rest.

That's 5,152 characters, about 1,290 tokens at a rough 4-chars-per-token rate, across every agent session I've ever run. Not much.




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