.bashrc_
The hidden tiger with teeth larger than a sabre-toothed tiger that no one ever talks about. Until now.
The Hidden Tiger
Why .bashrc is the most underrated file in Linux
I've been writing bash environment files for two decades. Nobody talks about .bashrc with anything close to the reverence it deserves. This is the opening shot of a series that fixes that.
Read the opener.bashrc.local
How to support personal customization without breaking config-as-code
If a managed file is overwritten on every Ansible run, your engineers will fight it. The trick is a sibling file — ~/.bashrc.local — that the managed system sources but never touches. Convention beats configuration here.
Read articleOne File, Whole Fleet
/etc/<org>/bash-env.sh + an Ansible role = fleet-wide bash consistency
Per-user .bashrc files are where bash environment goes to die. The escape hatch: a single fleet-wide bash environment file at /etc/<org>/bash-env.sh, slim per-user wrappers, and an Ansible role that owns the whole thing.
Read articleStop Putting Secrets in .bashrc
A real story about a database password I found in a .bashrc this week
A production user on a production box had MYSQL_PWD exported in a world-readable .bashrc. Anyone who could `ls /home/<user>/` could read it. Here's why this is one of the most common dotfile mistakes — and the three-file split that fixes it.
Read articleConditional Aliases
A .bashrc that doesn't break on a fresh VM
The single pattern — `command -v X >/dev/null && ...` — that lets one .bashrc work on every box in your fleet without error spam or hard dependencies. Plus the `[ -d /opt/foo ]` companion for path-conditional blocks.
Read articleColor-Coding Your Prompt So You Don't `rm -rf` Production
Red prompts on prod boxes have stopped me twice this year
A 6-line PS1 modification that color-codes your prompt by environment — red on prod, yellow on staging, green on dev — and the operational logic of why that single visual signal beats every alias and confirmation prompt ever invented.
Read articleHistory Is Not Just up-arrow
HISTSIZE, HISTCONTROL, PROMPT_COMMAND, and the multi-tab problem
The default bash history settings lose commands, eat duplicates, and confuse you across tabs. Five lines of .bashrc turn shell history into an actual research tool.
Read article