If you utilize Git bash, you can produce & use the aliases, to try this, first generate/update profile file::GetJavaVersion set "JavaVersion=" if "%~1"=="" ( established /p JavaVersion="Kind the most important java Edition variety you want to change to: " ) else ( set /a JavaVersion="%~1" ) exit /b rem Update JAVA_HOME user variable with hardcoded