Is it possible to create a tap for Homebrew, so we could install and configure it about the Homebrew PackageManager?
Done.
Install:
brew install romkatv/powerlevel10k/powerlevel10k
echo 'source /usr/local/opt/powerlevel10k/powerlevel10k.zsh-theme' >>! ~/.zshrc
Update:
brew update && brew upgrade
I got some errors could you help me with them:
prompt_context:33: command not found: _prompt_segment
prompt_os_icon:1: command not found: _prompt_segment
prompt_dir:245: command not found: _prompt_segment
prompt_command_execution_time:28: command not found: _prompt_segment
prompt_status:32: command not found: _prompt_segment
prompt_time:3: command not found: _prompt_segment
These errors don't look like they come from powerlevel10k. Are you trying to load several zsh themes at the same time?
Could you post your zshrc?
@romkatv Yes take a look here:
#Theme 2 Load
ZSH_THEME="powerlevel9k/powerlevel9k"
#POWERLEVEL9k functions
#WIFI SIGNAL
zsh_wifi_signal(){
local signal=$(/System/Library/PrivateFrameworks/Apple80211.framework/Versions/Current/Resources/airport -I | grep CtlRSSI | awk '{print $2}')
local color='%F{yellow}'
[[ $signal -gt -60 ]] && color='%F{green}'
[[ $signal -lt -70 ]] && color='%F{red}'
echo -n "%{$color%}\uf424 %{%f%}"
}
# File search functions
function f() { find . -iname "*$1*" ${@:2} }
function r() { grep "$1" ${@:2} -R . }
# Create a folder and move into it in one command
function mkcd() { mkdir -p "$@" && cd "$_"; }
#POWERLEVEL10K Config
#source /usr/local/opt/powerlevel10k/powerlevel10k.zsh-theme
#POWERLEVEL9 Config
#DEFAULT USER
DEFAULT_USER='ozw00d'
#FONTCONFIG
#POWERLEVEL9K_MODE='nerdfont-complete'
#POWERLEVEL9K_MODE='awesome-patched'
POWERLEVEL9K_MODE='awesome-fontconfig'
#LEFT SEGMENT SEPARATOR
#POWERLEVEL9K_LEFT_SEGMENT_SEPARATOR=$'\uE0B1'
#SHOW LINE CONFIG
#Double-Lined Prompt
POWERLEVEL9K_PROMPT_ON_NEWLINE=true
POWERLEVEL9K_PROMPT_ADD_NEWLINE=true
POWERLEVEL9K_RPROMPT_ON_NEWLINE=true
POWERLEVEL9K_MULTILINE_FIRST_PROMPT_PREFIX="%F{blue}\u256D\u2500%f"
POWERLEVEL9K_MULTILINE_LAST_PROMPT_PREFIX="%F{blue}\u2570\uf460%f "
#LEFT SEGMENTS
POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(context os_icon root_indicator dir dir_writable ssh)
#CONTEXT
POWERLEVEL9K_CONTEXT_DEFAULT_FOREGROUND="038"
POWERLEVEL9K_CONTEXT_DEFAULT_BACKGROUND="234"
POWERLEVEL9K_CONTEXT_ROOT_FOREGROUND="231"
POWERLEVEL9K_CONTEXT_SUDO_FOREGROUND="231"
POWERLEVEL9K_CONTEXT_REMOTE_FOREGROUND="208"
POWERLEVEL9K_CONTEXT_REMOTE_SUDO_FOREGROUND="088"
POWERLEVEL9K_CONTEXT_ROOT_BACKGROUND="001"
POWERLEVEL9K_CONTEXT_SUDO_BACKGROUND="167"
POWERLEVEL9K_CONTEXT_REMOTE_BACKGROUND="002"
POWERLEVEL9K_CONTEXT_REMOTE_SUDO_BACKGROUND="197"
#OS ICON
POWERLEVEL9K_OS_ICON_BACKGROUND="234"
#RIGHT-SEGMENTS
POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=(command_execution_time status custom_wifi_signal time)
#status indicator
POWERLEVEL9K_STATUS_VERBOSE=false
POWERLEVEL9K_STATUS_OK_IN_NON_VERBOSE=true
POWERLEVEL9K_STATUS_VERBOSE=false
#Wifi Signal
POWERLEVEL9K_CUSTOM_WIFI_SIGNAL="zsh_wifi_signal"
POWERLEVEL9K_CUSTOM_WIFI_SIGNAL_BACKGROUND="016"
#Command Execution Time Threshold
POWERLEVEL9K_COMMAND_EXECUTION_TIME_THRESHOLD=0
#Command Execution Time
POWERLEVEL9K_COMMAND_EXECUTION_TIME_BACKGROUND='black'
POWERLEVEL9K_COMMAND_EXECUTION_TIME_FOREGROUND='blue'
#TIME
POWERLEVEL9K_TIME_BACKGROUND="234"
POWERLEVEL9K_TIME_FOREGROUND="152"
POWERLEVEL9K_TIME_FORMAT="%D{%H:%M:%S}"
#POWERLEVEL9K_TIME_FORMAT="%D{\UF133 %d.%m.%y %H:%M:%S}"
#DIR WRITEABLE
POWERLEVEL9K_DIR_WRITABLE_FORBIDDEN_FOREGROUND="001"
POWERLEVEL9K_DIR_WRITABLE_FORBIDDEN_BACKGROUND="016"
#DIR COLOURS
POWERLEVEL9K_DIR_HOME_BACKGROUND="233"
POWERLEVEL9K_DIR_HOME_FOREGROUND="152"
POWERLEVEL9K_DIR_HOME_SUBFOLDER_BACKGROUND="016"
POWERLEVEL9K_DIR_HOME_SUBFOLDER_FOREGROUND="062"
#DIR CONFIG
POWERLEVEL9K_SHORTEN_DIR_LENGTH=2
POWERLEVEL9K_SHORTEN_STRATEGY="truncate_beginning"
#POWERLEVEL9K_FOLDER_ICON=''
#Unneccessary Items
#POWERLEVEL9K_TIME_FORMAT="\UF43A %D{%I:%M \UF133 %m.%d.%y}"
#RVM
#POWERLEVEL9K_RVM_BACKGROUND="black"
#POWERLEVEL9K_RVM_FOREGROUND="249"
#POWERLEVEL9K_RVM_VISUAL_IDENTIFIER_COLOR="red"
#POWERLEVEL9K_RVM_BACKGROUND="black"
#POWERLEVEL9K_RVM_FOREGROUND="249"
#POWERLEVEL9K_RVM_VISUAL_IDENTIFIER_COLOR="red"
#VCS
#POWERLEVEL9K_VCS_CLEAN_FOREGROUND='black'
#POWERLEVEL9K_VCS_CLEAN_BACKGROUND='green'
#POWERLEVEL9K_VCS_UNTRACKED_FOREGROUND='black'
#POWERLEVEL9K_VCS_UNTRACKED_BACKGROUND='yellow'
#POWERLEVEL9K_VCS_MODIFIED_FOREGROUND='white'
#POWERLEVEL9K_VCS_MODIFIED_BACKGROUND='black'
#POWERLEVEL9K_VCS_UNTRACKED_ICON='\u25CF'
#POWERLEVEL9K_VCS_UNSTAGED_ICON='\u00b1'
#POWERLEVEL9K_VCS_INCOMING_CHANGES_ICON='\u2193'
#POWERLEVEL9K_VCS_OUTGOING_CHANGES_ICON='\u2191'
#POWERLEVEL9K_VCS_COMMIT_ICON="\uf417"
HIST_STAMPS="mm/dd/yyyy"
# Add a space in the first prompt
#POWERLEVEL9K_MULTILINE_FIRST_PROMPT_PREFIX="%f"
# Visual customisation of the second prompt line
#local user_symbol="$"
#if [[ $(print -P "%#") =~ "#" ]]; then
# user_symbol = "#"
#fi
#POWERLEVEL9K_MULTILINE_LAST_PROMPT_PREFIX="%{%B%F{153}%K{black}%} $user_symbol%{%b%f%k%F{153}%} %{%f%}"
#DISABLE_UPDATE_PROMPT=true
# Uncomment the following line to enable command auto-correction.
ENABLE_CORRECTION="true"
#Plugins Configuration
plugins=(
adb
copydir
copyfile
cp
fd
iterm2
man
nmap
osx
rsync
git
docker
brew
zsh-syntax-highlighting
zsh-navigation-tools
zsh-autosuggestions
zsh-completions
zsh-navigation-tools
)
source $ZSH/oh-my-zsh.sh
# Preferred editor for local and remote sessions
if [[ -n $SSH_CONNECTION ]]; then
export EDITOR='mate'
else
export EDITOR='nano'
fi
# Lines configured by zsh-newuser-install
HISTFILE=~/.histfile
HISTSIZE=1000
SAVEHIST=1000
# End of lines configured by zsh-newuser-install
# The following lines were added by compinstall
zstyle :compinstall filename '/Users/0zzy/.zshrc'
autoload -Uz compinit
compinit
# End of lines added by compinstall
alias zshconfig="mate -w ~/.zshrc"
alias ohmyzsh="mate -w ~/.oh-my-zsh"
I think I have to change this line?:
#Theme 2 Load
ZSH_THEME="powerlevel9k/powerlevel9k"
Since you are using Oh My Zsh, you need to follow Powerlevel10k installation instructions for Oh My Zsh.
Alternatively, you can remove ZSH_THEME parameter from ~/.zshrc and then follow installation instructions for Homebrew.
Once you get powerlevel10k working, I highly recommend replacing custom_wifi_signal in POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS with wifi. Otherwise your prompt will be very slow.
I also recommend running p10k configure. If you like the results, you can remove all POWERLEVEL9K parameters from ~/.zshrc.
Ok thank you very much.
I changed my .zshrc a little with your help
and got two last Questions:

As you can see at the Picture at the Top, the configuration is a litte bit wrong (it felts so).
Things I want to get optimized:
1.) a little gap (Triangle and gap) between the Apple and the Home Symbol,
2.) My Username@HostName in the beginning of the first line,
3.) A real Wifi Symbol ( I uses in my old PLVL9K config a symbol from the awesome-fontconfig) take a look at the Picture at the Bottom, so you understand better what I mean.
<< It's my PLVL9k Config
This looks awful.
Please try the following:
p10k configure and agree to install the recommended font when asked. Restart iTerm2 again.p10k configure again and select what you like. This time it shouldn't ask to install the font and you should see all glyphs in the first 4 questions asked by the wizard.~/.zshrc that sources ~/.p10k.zsh. Keep that line at the bottom. Do not move it and do not put any POWERLEVEL9K parameters below it.~/.p10k.zsh and uncomment wifi. You can also move it to a different place within POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS or POWERLEVEL9K_LEFT_PROMPT_ELEMENTS.POWERLEVEL9K parameters from ~/.zshrc. They have no effect now.@romkatv ok i will check the points your'e mentioned.
But I don't use iTerm2 (I know in my plugins config it is in it ;) .
Other Questions:
1) How can I use my OMZSH plugins with plvl10k?
Everything else is working fine, thx for the help mate.
Everything looks clearer:
before plvl10k:

after:

but the wifi signal from p9k is working with a function, could I use this function also in p10k?
How can I use my OMZSH plugins with plvl10k?
You can use Oh My Zsh plugins as usual.
Most helpful comment
Since you are using Oh My Zsh, you need to follow Powerlevel10k installation instructions for Oh My Zsh.
Alternatively, you can remove
ZSH_THEMEparameter from~/.zshrcand then follow installation instructions for Homebrew.Once you get powerlevel10k working, I highly recommend replacing
custom_wifi_signalinPOWERLEVEL9K_RIGHT_PROMPT_ELEMENTSwithwifi. Otherwise your prompt will be very slow.I also recommend running
p10k configure. If you like the results, you can remove allPOWERLEVEL9Kparameters from~/.zshrc.