Mike Clonts
Mike Clonts

Reputation: 91

How to get CodenameOne Maven Project Running in Netbeans

Thx to Steve for the CN1 ant to maven migration tool and video here. - Has anyone been able to run the Kitchen Sink project in Netbeans after migration? I follow the video instructions with the migration tool and migrate successfully and it runs from command line with ./run.sh but when I go to run it in NetBeans, I had a lot of 501 (https needed) errors. Added umer's code from here and that solved the 501 errors but now get:

  1. Invalid POM for com.codenameone:codenameone-javase:jar:7.0.23, and
  2. No implementation for org.codehaus.plexus.languages.java.jpms.LocationManager was bound. while locating org.apache.maven.plugin.surefire.SurefirePlugin.

Note invalid POM warning...

------------------------------------------------------------------------
Building kitchensink-common 1.0-SNAPSHOT
------------------------------------------------------------------------

--- properties-maven-plugin:1.0.0:read-project-properties (default) @ kitchensink-common ---

--- codenameone-maven-plugin:7.0.23:generate-gui-sources (generate-gui-sources) @ kitchensink-common ---
The POM for com.codenameone:codenameone-javase:jar:7.0.23 is invalid, transitive dependencies (if any) will not be available, enable debug logging for more details
Generating GUI sources
No GUI Entries available

Running from command line, invalid POM warning disappears:

[INFO] -----------< com.codename1.demos.kitchen:kitchensink-common >-----------
[INFO] Building kitchensink-common 1.0-SNAPSHOT                           [4/5]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] 
[INFO] --- properties-maven-plugin:1.0.0:read-project-properties (default) @ kitchensink-common ---
[INFO] 
[INFO] --- codenameone-maven-plugin:7.0.23:generate-gui-sources (generate-gui-sources) @ kitchensink-common ---
Generating GUI sources
No GUI Entries available

Running on apache-maven-3.8.1 on MacOSX Java version: 1.8.0_172 Suggestions welcomed.

Thx, Mike

Upvotes: 1

Views: 193

Answers (2)

Mike Clonts
Mike Clonts

Reputation: 91

Problem was solved updating from Netbeans 8.2 to latest Netbeans version (currently 12.3).

Upvotes: 0

steve hannah
steve hannah

Reputation: 4716

I think perhaps the method I'm using to detect the latest version of cn1 has issues. It picked 7.0.23 which was released this morning. But then it was unable to find some of the jars.

Probably it will work if you just try running the project again as it should be fully propagated to maven central now.

Upvotes: 1

Related Questions