This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | "Run file" uses wrong JDK - through the maven-exec-plugin | ||
---|---|---|---|
Product: | projects | Reporter: | pekarna <pekarna> |
Component: | Maven | Assignee: | David Simonek <dsimonek> |
Status: | RESOLVED WORKSFORME | ||
Severity: | normal | CC: | jglick |
Priority: | P3 | ||
Version: | 6.x | ||
Hardware: | PC | ||
OS: | Linux | ||
URL: | http://stackoverflow.com/questions/2770476/wicket-app-in-embedded-jetty-causes-unsupportedclassversionerror/2770582 | ||
Issue Type: | DEFECT | Exception Reporter: |
Description
pekarna
2010-05-05 19:04:57 UTC
And, I forgot to add - there's no JAVA_HOME set in settings.xml. When I run the same command (which the exec plugin calls) from a shell, it works. Does this still happen when you ask to use exec-maven-plugin 1.2 in your POM? If so, duplicate of bug #188864. Cannot reproduce even in NB 6.9. I set an alternate Java Platform in the project's Compile properties panel, and when I Run Project or Run File, that JDK is used. System.err.println("running main in " + System.getProperty("java.version")); => NetBeans: Executing 'mvn -Dexec.classpathScope=runtime -Dexec.args=-classpath %classpath whatever.Main -Dexec.executable=/space/jdk7/bin/java -Dnetbeans.execution=true process-classes org.codehaus.mojo:exec-maven-plugin:1.1.1:exec' NetBeans: JAVA_HOME=/space/jdk7 ... [exec:exec] running main in 1.7.0-ea |