Extend $PATH variable in git bash under Windows

后端 未结 3 871
说谎
说谎 2021-02-05 06:33

I\'m trying to extend my $PATH variable in git bash (MinGW shell) by adding the following to the file ~/.bashrc

PATH=$PATH\':/c/Program Files/maven/apache-maven-         


        
3条回答
  •  一个人的身影
    2021-02-05 06:51

    Here are two ideas.

    You can have your path with double quote mark.

    export PATH=$PATH:"/C/Program Files (x86)/apache-maven-3.3.3/bin"

    Or, You can also make symbolic link for the directory.

    ln -s "/C/Program Files (x86)/apache-maven-3.3.3/bin" ./mvnbin
    export PATH=$PATH:/your-path/mvnbin

    It works for me in mingw32 environment.

提交回复
热议问题