Tool library for starting model applications.
The system needs to install Java and Maven, you can execute java and mvn in the console terminal normally.
Find an empty directory and create a pom.xml file in this directory. The sample content of pom.xml is as follows.
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <artifactId>yourproject</artifactId> <version>1.0.0-SNAPSHOT</version> <packaging>jar</packaging> <groupId>org.xworker</groupId> <name>yourporjectname</name> <build> <plugins> <!-- Copy the dependent jar package to the lib directory --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-dependency-plugin</artifactId> <version>2.10</version> <executions> <execution> <id>copy</id> <phase>package</phase> <goals> <goal>copy-dependencies</goal> </goals> <configuration> <outputDirectory> ${project.basedir}/lib/ </outputDirectory> </configuration> </execution> </executions> </plugin> </plugins> </build> <dependencies> <dependency> <groupId>org.xworker</groupId> <artifactId>xworker_startup</artifactId> <version>1.0.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.xworker</groupId> <artifactId>xworker_swt_thingeditor</artifactId> <version>1.4.5-SNAPSHOT</version> </dependency> </dependencies> <repositories> <repository> <id>sonatype</id> <name>sonatype Repository</name> <url>https://oss.sonatype.org/content/groups/public/</url> <releases> <enabled>false</enabled> </releases> <snapshots> <enabled>true</enabled> </snapshots> <layout>default</layout> </repository> </repositories> </project>
In the above pom.xml file, you can also introduce other dependencies as needed. What is introduced here is the startup and swt model editors.
Execute the following command in the console.
mvn package
If the execution is successful, you can see that a lib directory has been created in the current directory, and related dependencies have been copied to this directory.
When the mvn package command is successfully executed, you can execute the following command to create an execution script.
java -cp ./lib/xworker_startup-1.0.1-SNAPSHOT.jar xworker.startup.Startup ./ xworker.thingeditor.Setup run
The following script files will be created based on the imported dependencies.
Copyright © 2007-2019 XWorker.org 版权所有 沪ICP备08000575号