Search code examples
command-lineterminalzshzshrc

Pure Prompt install issues


I tried to install pure prompt for my terminal, but I don't think it has worked. Instead everytime I open terminal, I get this at the top:

Usage: prompt <options>
Options:
    -c              Show currently selected theme and parameters
    -l              List currently available prompt themes
    -p [<themes>]   Preview given themes (defaults to all)
    -h [<theme>]    Display help (for given theme)
    -s <theme>      Set and save theme
    <theme>         Switch to new theme immediately (changes not saved)

Use prompt -h <theme> for help on specific themes.

Am I correct in thinking this is not supposed to show up? Also when I view all the themes, pure is not there. How should I resolve this?

My .zshrc file contains the following:

setopt AUTO_CD
# initialise nice autocompletion
autoload -U compinit && compinit

# do not autoselect the first completion entry
unsetopt MENU_COMPLETE
unsetopt FLOW_CONTROL
# show completion menu on successive tab press
setopt AUTO_MENU
setopt COMPLETE_IN_WORD
setopt ALWAYS_TO_END

# use a pretty menu to select options
zstyle ':completion:*:*:*:*:*' menu select

# initialize pure prompt
autoload -U promptinit; promptinit
prompt pure

Solution

  • How did you install Pure? You need to make sure its directory is added to your $fpath, before you call promptinit:

    fpath+=( /path/to/pure )
    autoload -Uz promptinit
    promptinit
    prompt pure
    

    —-

    Note: This goes for any theme you want to use with promptinit, not just Pure.