We depend too much on automatic things like maven and ant sometimes and forget how to to the simple things. For example – how do you compile a java program on the command line and use a jar like jdom-1.0.jar and then run that with the java command finding the dependencies in the jar.
rm *.class
javac -extdirs . HelloWorld.java
java -cp .:jdom-1.0.jar HelloWorld
Daily Archives: April 10, 2007
Sometimes it is the Simplest Thing…
We depend too much on automatic things like maven and ant sometimes and forget how to to the simple things. For example – how do you compile a java program on the command line and use a jar like jdom-1.0.jar and then run that with the java command finding the dependencies in the jar.
rm *.class
javac -extdirs . HelloWorld.java
java -cp .:jdom-1.0.jar HelloWorld