How to persistently set a variable in Windows 7 from a batch file?

前端 未结 7 1173
無奈伤痛
無奈伤痛 2020-12-02 08:38

I am trying to set the PATH environment variable in windows 7 using a bat-file; however it does not seem to work.

I am using this windows command:

se         


        
7条回答
  •  無奈伤痛
    2020-12-02 09:28

    Use This command setx PATH "%PATH%;%MVN_HOME%\bin\"

    Anyways it wont be set in current session you need to use

    set PATH="%PATH%;%MVN_HOME%\bin\"

提交回复
热议问题