This post is part of the $HOME... series.

Falling backwards into POSIX.

Background

I have been using zsh for over a decade now. For the most part, this has been across machines I largely have administrative control over. HPC systems are always a notable exception. Over the past half year, I’ve found myself working on dozens of machines where even chezmoi and pixi~/~micromamba workflows cannot comfortably bring $HOME ergonomics 1.

The road to bash is paved with $SHELL s

There are far too many today to bother enumerating, but in short order 2:

nushell
Pleasant for many use-cases, the process of converting my dotfiles was fairly repetitive, and its incompatibility with spack made it a non-starter 3.
fish
Adopted to resolve the spack issue. However, I found I was the wrong audience for it; features like global, browser-based customization are not useful for my terminal-centric, chezmoi focused workflow 4.
xonsh
Ergonomic, and better than subprocess for scripts, but a non-starter in terms of being a good $SHELL 5

For the most part I had resigned myself to fish. It was fast, needed very few plugins 6.

Eventually I came across this post by Cody Hiar on ble.sh, and decided to take the plunge and shift back. A driving force for this is also that most of my dotfiles focus on using rust equivalents of what used to purely SHELL specific themes / tools; e.g. starship over powerline10k.

Caveats

ble.sh is great but it isn’t a catch-all solution. In particular, there are still inherent issues with using bash as a customized shell, due to concerns about clobbering settings from existing machines, e.g. lua module settings.

Conclusions

POSIX compatibility is here to stay on most machines. It is unlikely that this will change in the near future. To that end, it makes more sense to adaptively stick to bash and save my “strangeness budget7 for new-fangled programming languages instead of shells8.


  1. Also my zsh startup times hovered an intolerable 50ms, which I later found out was mostly due to spack ↩︎

  2. Discounting many more ephermeral tests ↩︎

  3. Fun for data pipelines and nicer multi-line commands ↩︎

  4. Plus breaking POSIX for the features offered seemed like a bad trade-off ↩︎

  5. i.e. barely any community support ↩︎

  6. So fewer failure modes than my favorite zsh ↩︎

  7. A concern I was recently re-sensitized to by Luthaf ↩︎

  8. At any rate, I do relish not having to transform one-liners from nushell and friends back to bash to pass to co-workers. ↩︎


Series info

$HOME... series

  1. Provisioning Dotfiles on an HPC
  2. Refactoring Dotfiles For Colemak
  3. HPC Dotfiles and LMod
  4. Dotfiles from dotgit to bombadil
  5. The State of my Dots
  6. Back to bash <-- You are here!