Setting up ZK Maven Archetype

From Documentation


Setting up ZK Maven Archetype



Stop.png This article is out of date, please refer to ZK Installation Guide/Quick Start/Create and Run Your First ZK Application with Eclipse and Maven for more up to date information.

Add ZK Maven Archetype

  • [Window] -> [Preferences] -> [Maven] --> [Archetypes]
    ZK Installation Guide Maven AddArchetype step1.png
  • Click Add Remote Catalog and type in the catalog file as illustrated:
    ZK Installation Guide Maven AddArchetype step2.png
http://mavensync.zkoss.org/maven2/
  • Click Verify and then OK to add the catalog.
    • If the Remote catalog is empty.[1]

  1. If an error message appears stating that the Remote catalog is empty, this is most likely due to a bug in the m2eclipse plugin in v0.12.x, MNGECLIPSE-2757. Until m2eclipse 0.13.x or newer versions are released and available, there are two possible workarounds:
    1. Install the "older version" 0.10.x from the Installing m2eclipse website. Users will first need to uninstall m2eclipse 0.12.x, restart, and then install 0.10.x available from the following site:
      http://m2eclipse.sonatype.org/sites/m2e/0.10.2.20100623-1649/
    2. Install the “newer version” from the following site: http://download.eclipse.org/technology/m2e/releases You first will need to uninstall m2eclipse 0.12.x, restart Eclipse before you can install the “newer” version from the website above. (Please note: the newer version of M2eclipse plugin is not compatible with the old Maven Project. Therefore you must enable your maven project with the latest M2eclipse plugin from the Installing m2eclipse website.)
    3. Create the plugin from the archetype using the Maven command line tool mvn, then use import existing maven project to add the generated project to Eclipse. For more details, please refer to Use the command line version of Maven to create a project.