I built sbsh: a tool to make terminal environments reproducible and persistent

I wanted to share a small open-source tool I have been building and using every day called sbsh. It lets you define your terminal environments declaratively, something I have started calling Terminal as Code, so they are reproducible and persistent.

πŸ”— Repo: github.com/eminwux/sbsh

πŸŽ₯Β Demo: using aΒ bash-demo profile

https://i.redd.it/2ajxmkfzx30g1.gif

Instead of starting a shell and manually setting up variables or aliases, you can describe your setup once and start it with a single command.

Each profile defines:

  • Environment variables
  • Working directory
  • Lifecycle hooks
  • Custom prompts
  • Which shell or command to run

Run sbsh -p bash-demo to launch a fully configured session.
Sessions can be detached, reattached, listed, and logged, similar to tmux, but focused on reproducibility and environment setup.

You can also define profiles that run Docker or Kubernetes commands directly.

πŸ“ Example profiles: docs/profiles

I would love feedback from anyone who enjoys customizing their terminal or automating CLI workflows. Would this be useful in your daily setup?

Leave a Reply