.zshrc エイリアスは powerlevel10k では動作しません。

.zshrc エイリアスは powerlevel10k では動作しません。

実行対象Raspbian GNU/Linux 11 (bullseye)

インストールしましたパワーレベル10kzsh用のシェルテーマがありますが、エイリアスが機能しないようです(例zsh: command not found: ll:)理由がわかりません...

私の.zshrcは次のようになります。

# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc.
# Initialization code that may require console input (password prompts, [y/n]
# confirmations, etc.) must go above this block; everything else may go below.
if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then
  source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
fi

source ~/shelltools/powerlevel10k/powerlevel10k.zsh-theme

# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh
source ~/shelltools/powerlevel10k/powerlevel10k.zsh-theme
source ~shelltools/powerlevel10k/powerlevel10k.zsh-theme

# git aliases
alias gca='git add .&&git commit -m '
alias gph='git push'
alias gpl='git pull'
alias gc='git checkout'
alias gcb='git checkout -b '
alias gcp='git checkout production'
alias gmp='git merge production'
alias gcd='git checkout develop'
alias gmd='git merge develop'

# some more ls aliases
alias ll='ls -l'
alias la='ls -A'
alias l='ls -CF'

エイリアスは行の後に宣言されるため、オーバーライドされてsourceいないようです。

ベストアンサー1

最終的に問題の原因が何であるかはわかりませんが、zshとpowerlevel10kテーマを再インストールしました(手動インストール)成功した​​。

おすすめ記事