InteliJ Idea in WSL2 error : export: ProgramFiles(x86): bad variable name

Viewed 666

I'm getting the error

export: ProgramFiles(x86): bad variable name

when trying to run a java program on WSL2 from IntelliJ Idea. I can't seem to find any log or lead to this error. Any help would be appreciated.

Thanks.

4 Answers

Disabled EnvFile plugin, I resolved this problem.

I don't know if you get the answer already, please uncheck your "include system environment variables" and save, it should works. enter image description here

I removed the .env files support and envFile dependencies

I know this isn't an exact answer, but I ran into the same problem. I removed a bunch of unused extensions and it solved the issue - sadly I don't know which was the culprit. So my advice is to disable all of your extensions and slowly enable them back to see which one is breaking it.

Related