Comments (7)
Yup, you are right. This seems to happen when there are multiple java versions inside your path. The script was supposed to remove them automatically but only does so when there's only one version. I will look into this as fast as possible. For now please remove them manually and everything should work fine. If you have any other questions feel free to ask. Thank you for your contribution
from jenv-for-windows.
I tried where java
and it gave me this:
C:\Program Files\Common Files\Oracle\Java\javapath\java.exe
C:\Program Files (x86)\Common Files\Oracle\Java\javapath\java.exe
C:\tools\jenv\java.bat
Does that mean I should get rid of the first two, so that the output becomes
C:\tools\jenv\java.bat
?
from jenv-for-windows.
Yea that's how it's supposed to be. I pushed hopefully a fix. Please test it.
from jenv-for-windows.
Now the script should remove at least any java from the user path. There could still be issues if you have java inside your system/machine path but java does not put them there when installed. Where java
should only point to jenvs java.bat
from jenv-for-windows.
@FelixSelter I pulled the latest code, and jenv
ran way faster and didn't mess up my terminal, but where java
still shows those two .exes. They're in my System's PATH, but I might have added them there manually, I don't remember.
There could still be issues if you have java inside your system/machine path but java does not put them there when installed.
If you don't remove them from the System's PATH, perhaps you could give a warning that the user needs to do it manually?
from jenv-for-windows.
Hi, Please update again. I changed the code so it requests you to restart with admin rights so it can automatically correct the system path. Thank you for your suggestion. Can this be closed now?
from jenv-for-windows.
Seems to work, thanks!
from jenv-for-windows.
Related Issues (20)
- Autoaccept defaults on "jenv autoscan" HOT 2
- Error when jEnv is on a Path with spaces HOT 1
- Success message when removing invalid jdk name HOT 1
- Make jenv for Windows have same commandline options and logic as https://www.jenv.be/ HOT 15
- Non destructive PATH configuration HOT 1
- Can't add a java version HOT 1
- JEnv is changing your environment variables. This process could take longer but it happens only when a jenv executable is found in your path HOT 10
- List registered JDKs HOT 2
- Using "jenv change" doesn't change JAVA_HOME for current session
- "jenv use" doesn't work in powershell HOT 11
- There is no way to show the current global version HOT 1
- Conflicts with other batch file executions on windows HOT 4
- bash: jenv: command not found in gitbash HOT 1
- "jenv list" not display jdk currently used after "jenv local" and then "jenv use" in a directory HOT 1
- Environment variable backup HOT 1
- Is this project still being updated? HOT 1
- support win7? HOT 1
- Using jenv change JAVA_HOME was successfully changed, but using java -version in other command line windows still shows the previous version that has not changed, but JAVA_HOME has changed. HOT 2
- The default javac version is used when the version is changed:bug
- 执行完后 java -version 变成特别慢了 HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jenv-for-windows.