[Solved] MAC m1 Command Error: complete:13: command not found: compdef

Mac M1 command line error   complete:13: command not found: compdef,

Solution:

code ~/.zshrc

Add in file

autoload -Uz compinit

compinit

Save and reopen the command line without any error.

autoload -Uz compinit
compinit
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion

Similar Posts: