Skip to main content

Switch from Powerlevel10k to Pure: A Minimal Zsh Prompt That Actually Works

terminal • zsh • developer workflow

A terminal prompt is not decoration—it is an instrument. When it fails to clearly communicate your present working directory, it fails its most basic responsibility. This guide replaces Powerlevel10k with Pure using a validated, failure-proof process based on real debugging outcomes, not assumptions.

This article corrects a critical issue: incomplete removal of Powerlevel10k leads to a broken mixed prompt state. Every step below ensures a clean, deterministic result.

Understanding the Shift

Powerlevel10k (GitHub) is optimized for performance and configurability. It exposes a large number of prompt segments and visual options, often resulting in information overload.

Pure (GitHub) takes the opposite approach. It displays only what is necessary: your directory, Git context, and command state. This constraint produces clarity.

Step 1 — Hard Reset the Shell (Non-Negotiable)

Start from a clean environment. This prevents Powerlevel10k from persisting in memory.

exec zsh -f

Validate:

echo $PROMPT

✔ No _p9k anywhere
✔ Simple default prompt

Step 2 — Remove Powerlevel10k Completely

nano ~/.zshrc

Remove all references:

ZSH_THEME="powerlevel10k/powerlevel10k" source ~/.p10k.zsh [[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh

Remove plugin manager entries:

zinit light romkatv/powerlevel10k zplug romkatv/powerlevel10k antigen bundle romkatv/powerlevel10k

Delete config file:

rm -f ~/.p10k.zsh

Step 3 — Install Pure (Validated)

mkdir -p ~/.zsh/pure git clone https://github.com/sindresorhus/pure.git ~/.zsh/pure

Verify installation:

ls ~/.zsh/pure

✔ Must contain pure.zsh and async.zsh

Step 4 — Minimal Working Configuration

nano ~/.zshrc

Use exactly this:

fpath+=("$HOME/.zsh/pure") autoload -U promptinit promptinit prompt pure

Step 5 — Clean Reload

exec zsh

Do not use source ~/.zshrc. It does not reset the shell state.

Step 6 — Ensure Full Directory Visibility

prompt_pwd() { print -P "%~" }

Step 7 — Apply Readable Colors and Layout

prompt_pure_precmd() { PROMPT="%F{51}%~%f" if [[ -n $vcs_info_msg_0_ ]]; then PROMPT+=" %F{244}${vcs_info_msg_0_}%f" fi PROMPT+=$'\n' PROMPT+="%F{46}❯%f " }

Validation — Confirm Everything Works

1. Pure is active

echo $PROMPT

2. Directory is correct

pwd

3. Git integration works

git init test cd test

4. Final prompt

~/your/full/path ❯

Result

You now have a prompt that is:

  • Readable at a glance
  • Accurate (no hidden path segments)
  • Minimal but functional
  • Free from Powerlevel10k conflicts

FAQ

The prompt didn’t change. What failed?

Powerlevel10k is still loaded. Remove all references and run exec zsh.

Why did I see _p9k_*?

That indicates Powerlevel10k is still active in memory.

Why use exec zsh?

It guarantees a clean shell. source does not.

Why is my path shortened?

Pure shortens paths by default. Override with prompt_pwd().

Why did \n appear?

Use $'\n' instead of "\n".

How do I verify success?

Ensure no _p9k and confirm pwd matches your prompt.

Comments