# oh-my-posh — Cross-Platform Prompt Theme Engine > Customizable prompt theme engine for any shell on any OS, with 100+ built-in themes, Git status, and language segment support. ## Install Save as a script file and run: # oh-my-posh — Cross-Platform Prompt Theme Engine ## Quick Use ```bash # macOS / Linux brew install jandedobbeleer/oh-my-posh/oh-my-posh # Windows winget install JanDeDobbeleer.OhMyPosh ``` ```bash # Add to ~/.bashrc, ~/.zshrc, or $PROFILE eval "$(oh-my-posh init bash --config 'https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/agnoster.omp.json')" ``` ## Introduction oh-my-posh is a cross-platform prompt theme engine that works with Bash, Zsh, Fish, PowerShell, cmd, and Nushell on Linux, macOS, and Windows. It renders rich prompt segments showing Git status, language versions, cloud contexts, and execution time using a single JSON or YAML configuration file. ## What oh-my-posh Does - Renders customizable prompt segments for Git status, language versions, and cloud contexts - Ships with 100+ community themes that work across all supported shells - Supports Nerd Font icons, Unicode glyphs, and emoji in prompt segments - Shows execution time, exit codes, battery level, and system information - Configures via a single JSON, YAML, or TOML file shared across shells ## Architecture Overview oh-my-posh is a compiled Go binary that shells invoke as an external command during prompt rendering. The binary reads a theme configuration file, evaluates each segment (Git, Node, Python, AWS, etc.) by inspecting the current environment, and emits ANSI-escaped strings that the shell displays. Because it runs as an external process, it works identically across all supported shells without shell-specific plugins. ## Setup & Configuration - Install via Homebrew, Winget, Scoop, or download the binary directly - Initialize in your shell profile with `eval "$(oh-my-posh init )"` - Point `--config` to a local file or remote URL for your theme - Customize segments by editing the JSON/YAML theme file - Install a Nerd Font for icon rendering: `oh-my-posh font install` ## Key Features - Works on every major shell and operating system with one binary - 100+ built-in themes with instant preview via the documentation site - Segments for 50+ tools: Git, Docker, Kubernetes, AWS, Python, Node, Rust, and more - Transient prompt support to clean up previous prompts after execution - Tooltip segments that appear contextually based on the current command ## Comparison with Similar Tools - **Starship** — Rust-based, minimal by default; oh-my-posh offers richer theming and more segments - **Powerlevel10k** — Zsh-only with instant prompt; oh-my-posh is cross-shell and cross-platform - **Pure** — Zsh-only minimalist prompt; oh-my-posh provides full customization - **Agnoster** — single theme, oh-my-posh ships 100+ themes and custom segment support ## FAQ **Q: Does oh-my-posh slow down my shell?** A: Prompt rendering typically takes 20-50ms. Disable heavy segments like Git in large repos if latency is noticeable. **Q: Can I use oh-my-posh with Windows Terminal?** A: Yes. It works with Windows Terminal, ConEmu, Alacritty, and any terminal that supports ANSI escape codes. **Q: Do I need a Nerd Font?** A: Nerd Fonts are recommended for icon rendering. Without one, you can use Unicode-only themes or plain text segments. **Q: Can I share one config across Bash, Zsh, and PowerShell?** A: Yes. The same JSON/YAML theme file works across all shells since oh-my-posh is shell-agnostic. ## Sources - https://github.com/JanDeDobbeleer/oh-my-posh - https://ohmyposh.dev --- Source: https://tokrepo.com/en/workflows/asset-91da5dfd Author: Script Depot