![]() You don't need to specify where your dependencies are since Maven handles that for you in the pom.xml file. Click in Directory and point to maven directory installed, for example: c:apache-maven-3.6.3.To use maven: mvn exec:java -Dexec.mainClass="" -Dexec.args="" If you would like that Eclipse uses your Maven installation, redirect it in Eclipse config: Window -> Preferences -> Maven -> Installations. Note that if your /etc/hosts file does not include an entry for your computerâs hostname, then many unit tests may execute slowly due to DNS lookups to translate your hostname to an IP address in InetAddress::getLocalHost. However, refixing the folder structure might be a pain. To build and install Log4j in your local Maven cache, from the parent project directory, and using Java 7 or 8, run: mvn install. You could then use maven on the other computer to run the program or pass the folder as an argument to java. This will download all your dependencies into the. Yes, using the terminal (or cmd prompt) go to your folder where your pom file is located and type: mvn clean compile ![]() ![]() "Is there a way to automatically download the needed dependencies on the new computer?" It's a cool tool and allows you to shrink dependency jars, usually used for android (Try using their obfuscator too). In order to combat the large dependency jars, you could use ProGuard. ![]() So to answer the first question, as you suggested you could bundle your dependencies in a jar and use the jar to extract your dependencies and use the java code.
0 Comments
Leave a Reply. |