Skip to content

oh my posh setup for terminal

Sunny edited this page Sep 7, 2025 · 1 revision

## oh my posh setup for terminal

oh-my-posh is a great tool to make your terminal look clean, modern, and informative — especially when paired with Nerd Fonts. Let’s get your Oh My Posh setup done properly in your terminal (e.g., Kitty, Foot, etc.) under Arch Linux + Hyprland.

✅ 1. Install Oh My Posh

sudo pacman -S oh-my-posh

✅ 2. Install a Nerd Font (if not already)

Oh My Posh needs a Nerd Font to show symbols/icons correctly.

Recommended:

sudo pacman -S ttf-jetbrains-mono-nerd

Or:

sudo pacman -S ttf-cascadia-code-nerd

✅ 3. Set Your Terminal Font

For Kitty (~/.config/kitty/kitty.conf):

font_family JetBrainsMono Nerd Font bold_font auto italic_font auto font_size 11

For Foot (~/.config/foot/foot.ini):

[main] font=JetBrainsMono Nerd Font:size=11

Restart your terminal after saving.

## ✅ 4. Choose a Theme

List all themes:

oh-my-posh theme list

Preview a theme (e.g., aura):

oh-my-posh init bash --config $(oh-my-posh get shell --shell bash --config jandedobbeleer) | tee /dev/tty | source /dev/stdin

Or for Zsh:

oh-my-posh init zsh --config $(oh-my-posh get shell --shell zsh --config jandedobbeleer) | source

✅ 5. Set Up Permanent Prompt

🐚 For Bash

In ~/.bashrc, add:

eval "$(oh-my-posh init bash --config ~/.poshthemes/jandedobbeleer.omp.json)"

🐚 For Zsh

In ~/.zshrc, add:

eval "$(oh-my-posh init zsh --config ~/.poshthemes/jandedobbeleer.omp.json)"

✅ 6. Download Theme File

mkdir -p ~/.poshthemes cd ~/.poshthemes

curl -s https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/jandedobbeleer.omp.json -o jandedobbeleer.omp.json

chmod 644 jandedobbeleer.omp.json

Or replace with any other theme you like from: 👉 https://ohmyposh.dev/docs/themes

✅ 7. Restart Terminal

Now open a new terminal window, and you should see your beautiful oh-my-posh prompt in action.