Oh My Bash: it replaces your .bashrc, and the backup is the whole safety story
A delightful community-driven framework for managing your bash configuration, and an auto-update tool so that makes it easy to keep up with the latest updates from the community.
At a glance
- What is it?
- Oh My Bash is a community-driven framework that manages your bash configuration, and its whole install is one line that pipes a remote script into bash and overwrites ~/.bashrc. The documentation is unusually honest about the consequences: the original file is renamed with a timestamp, an --unattended flag exists for people who do not want the script changing their default shell, and the themes section admits the project got carried away.
- Who is it for?
- Oh My Bash suits someone already living in bash who wants prompt features and plugins without adopting zsh, and who reads the install script before piping it into a shell. It does not suit you if you want a prompt framework that is not bash, and it does not suit you if you keep critical state in ~/.bashrc and do not read what the installer does to it.
- Can I use it commercially?
- Yes. MIT is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
- Is it still maintained?
- Yes. The repository last received commits 17 days ago.
- What is it written in?
- Mainly Shell, according to GitHub's language statistics.
Answers come from the project's GitHub data, last synced on November 13, 2026, and from our analysis. They are not legal advice.
Star history
- ohmybash/oh-my-bash7,770 ★ · +58
| Repository | 2026-09-22 | 2026-11-13 |
|---|---|---|
| ohmybash/oh-my-bash | 7.7k | 7.8k |
58 Stars in the last 52 days, measured from the daily GitHub snapshot. Compare with other projects
Editorial analysis
One curl into bash, and a timestamped copy of your .bashrc
The basic installation is one line, in two flavours that differ only in the fetcher.
bash -c "$(curl -fsSL https://raw.githubusercontent.com/ohmybash/oh-my-bash/master/tools/install.sh)"bash -c "$(wget https://raw.githubusercontent.com/ohmybash/oh-my-bash/master/tools/install.sh -O -)"What that script does is stated plainly: this replaces `~/.bashrc` with the version provided by Oh My Bash. The original is backed up with the name `~/.bashrc.omb-TIMESTAMP`.
So the safety story is one renamed file, and it is worth checking that it exists before you trust anything else. The project does not merge into your configuration; it takes its place.
There is also a `.bash_profile` wrinkle. If `~/.bash_profile` does not exist, the installer creates one with default contents. If it did exist, the README warns to make sure it contains `source ~/.bashrc`, and gives the three lines to add if it does not:
if [[ -f ~/.bashrc ]]; then
source ~/.bashrc
fiPlugins are a bash array, and conditionals are just bash
Enabling plugins means editing one line in `.bashrc`.
plugins=(git bundler osx rake ruby)And the README shows how to make that conditional without leaving the list, which is the detail worth copying:
``` bash [ "$SSH_TTY" ] && plugins+=(tmux-autoattach) ```
So auto-attaching tmux happens on SSH sessions only, and it is a shell test on `$SSH_TTY` with an array append. There is no plugin condition syntax to learn.
The plugin catalogue lives in a `plugins/` directory and on the wiki, and the README's expectation is stated with a parenthetical: most plugins (should! we're working on this) include a README documenting how to use them.
A hundred themes, and an admission that they went too far
The themes section opens by confessing something. Early in the Oh My Bash world, we may have gotten a bit too theme happy. We have over one hundred themes now bundled.
Selecting one is a single environment variable:
OSH_THEME="font"and the default is explained rather than defended: the font theme is the default one, it is not the fanciest, it is not the simplest, it is just the right one for the original maintainer.
Switching is editing the value, and one of the examples carries its own dependency:
OSH_THEME="agnoster" # (this is one of the fancy ones)
# you might need to install a special Powerline font on your console's host for this to work
# see https://github.com/ohmybash/oh-my-bash/wiki/Themes#agnosterThat is a Powerline font requirement surfacing as a comment in a config file, which is the honest place for it.
There is also a random mode. `OSH_THEME="random"` picks one per terminal window, and the selection is controllable rather than pure chance: `OMB_THEME_RANDOM_CANDIDATES` is an array to draw from, `OMB_THEME_RANDOM_IGNORED` is an array to avoid, and the choice can be inspected with `echo "$OMB_THEME_RANDOM_SELECTED"`.
Three install flags for people who do not want a shell rewrite
The Advanced Installation section exists for people who want to change the default path or install without supervision, and it covers the OSH variable plus two flags, --unattended and --prefix.
The default install location is `~/.oh-my-bash`, hidden in your home directory. You can move it with the `OSH` environment variable, set before the install or before the end of the install pipeline:
export OSH="$HOME/.dotfiles/oh-my-bash"; bash -c "$(curl -fsSL https://raw.githubusercontent.com/ohmybash/oh-my-bash/master/tools/install.sh)"For an automated install, `--unattended` has the effect of not trying to change the default shell, and also not running `bash` when the installation finishes. So an unattended install leaves your shell alone and does not start bash afterwards:
bash -c "$(curl -fsSL https://raw.githubusercontent.com/ohmybash/oh-my-bash/master/tools/install.sh)" --unattendedAnd for a system-wide install, `--prefix=PREFIX` puts it in `/usr/local/share/oh-my-bash` for `--prefix=/usr/local`.
A system-wide install does not configure your shell, on purpose
The system-wide route has one consequence that is easy to miss.
To enable Oh My Bash after a system-wide installation, the bash startup file `.bashrc` needs to be manually set up by each user. The template is at `PREFIX/share/oh-my-bash/bashrc`, and users copy it themselves and edit it:
cp /usr/local/share/oh-my-bash/bashrc ~/.bashrcThat is a deliberate difference from the default install, which replaces your file. A system-wide install leaves the choice with each user, which is right for a shared machine and means one more step on a personal one.
There is also a manual path that skips the script entirely: clone the repository to `~/.oh-my-bash` with `git clone https://github.com/ohmybash/oh-my-bash.git ~/.oh-my-bash`.
The prerequisites section is short and specific: a Unix-like system, macOS or Linux, with curl or wget and git installed. It also carries a disclaimer that Oh My Bash works best on macOS and Linux.
So Windows is not in the supported list.
The repository is mostly plugins and themes, and has no releases
The root listing is the project's actual size. There is `plugins/`, `themes/`, `aliases/`, `completions/`, `templates/`, `custom/`, `cache/`, `log/`, `lib/`, `tools/`, `img/`, plus `oh-my-bash.sh`, `LICENSE.md`, `CONTRIBUTING.md`, `CODE_OF_CONDUCT.md` and `README.md`.
The build tooling is thin, which suits a shell framework: `.editorconfig`, `.shellcheckrc`, `.gitattributes`, `.git-blame-ignore-revs` and `.github/` for the workflows. ShellCheck is configured at the root.
There are no GitHub releases at all, which matches a project whose distribution mechanism is a curl of a script from `master`. The last push was on 2026-10-28.
So there is no version to pin. The install line fetches `tools/install.sh` from the `master` branch, which means the behaviour of your shell prompt is whatever that branch contained at the moment you ran it, and the timestamped `.bashrc` backup is the only artefact you can reason about afterwards.
Editorial conclusion
Oh My Bash suits someone already living in bash who wants prompt features and plugins without adopting zsh, and who reads the install script before piping it into a shell. It does not suit you if you want a prompt framework that is not bash, and it does not suit you if you keep critical state in ~/.bashrc and do not read what the installer does to it. Verify three things before you run it: that the timestamped backup of your .bashrc exists afterwards, since that file is your only way back, whether your login shell should be changed, which the `--unattended` flag exists to prevent, and that the install path is one you can write down, since the `OSH` variable controls it and the system-wide `--prefix` route does not set up `.bashrc` for you at all.
Frequently asked questions
How do I install oh my bash?
Run `bash -c "$(curl -fsSL https://raw.githubusercontent.com/ohmybash/oh-my-bash/master/tools/install.sh)"` or the wget equivalent, on a Unix-like system with curl or wget and git installed. The installer replaces ~/.bashrc and backs the original up as ~/.bashrc.omb-TIMESTAMP. For a scripted install add --unattended so it does not change your default shell, and for a system-wide install add --prefix=/usr/local.
what is oh my bash
An open source, community-driven framework for managing your bash configuration, MIT licensed, providing plugins, over one hundred bundled themes, aliases and completions. Plugins are enabled through a `plugins=(...)` array in ~/.bashrc and can be made conditional with ordinary shell tests such as `[ "$SSH_TTY" ] && plugins+=(tmux-autoattach)`. The default install directory is ~/.oh-my-bash and can be changed with the OSH environment variable.
What is an alternative to oh-my-zsh for bash?
Oh My Bash is an open source, community-driven framework for managing bash configuration, with plugins enabled from an array in ~/.bashrc and a theme chosen with the OSH_THEME variable. Its themes section points readers to the oh-my-zsh wiki for theme screenshots.
Official sources
Was this useful?