Created
May 12, 2019 11:46
-
-
Save vegetaz/5b7b30d397c7443389102a88df46d2ec to your computer and use it in GitHub Desktop.
bat/cmd file to set java home path
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
echo Setting JAVA_HOME | |
setx -m JAVA_HOME "C:\Program Files\Java\jdk1.8.0_212" | |
echo JAVA_HOME: %JAVA_HOME% | |
echo setting PATH | |
setx -m PATH "%Path%;%JAVA_HOME%\bin" | |
echo PATH: %PATH% | |
echo Display java version | |
java -version | |
pause |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment