Command not found - Oh-My-Zsh

前端 未结 12 946
佛祖请我去吃肉
佛祖请我去吃肉 2020-12-25 11:54

I recently installed zsh and oh-my-zsh in my Mac. Now when I try to run a maven command from the terminal, I am getting the following error.

$ mvn install
zs         


        
12条回答
  •  太阳男子
    2020-12-25 12:38

    As mentioned by @4ae1e1 in his comment, $ have to be added before M2_HOME while referring it in the PATH variable, as follows:

    export M2_HOME=/Applications/apache-maven-3.3.3
    export PATH=$PATH:$M2_HOME/bin/
    

    Once added, as others suggested, source the ~/.zshrc file.

提交回复
热议问题