Installing CLASSPATH for Duke to work properly

When I try to run Duke (open source reduplication program) I get a java class that hasn't found any errors. I did the following to add the correct files to the Classpath.

This is what the developer says to run the program: "You need an XML configuration file to run Duke. You also need to put duke .jar and lucene - .jar in the classpath."

To start Duke, issue the command:

java no.priv.garshol.duke.Duke

      

after learning about the classpath, this is what I ran into:

Kyles-MBP:~ kyleanderson$ export CLASSPATH="/Users/kyleanderson/Desktop/duke-1.2/duke-**.jar:/Users/kyleanderson/Desktop/duke-1.2/lucene-**.jar"
Kyles-MBP:~ kyleanderson$ java no.priv.garshol.duke.Duke

      

when i try to run the main class i get the following errors:

Exception in thread "main" java.lang.NoClassDefFoundError: no/priv/garshol/duke/Duke
Caused by: java.lang.ClassNotFoundException: no.priv.garshol.duke.Duke
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)

      

I looked around a bunch here and didn't answer my question.

+3


source to share


1 answer


this is:



export CLASSPATH=$CLASSPATH:/Users/kyleanderson/Desktop/duke-1.2/*:/Users/kyleanderson/Desktop/duke-1.2/*
java no.priv.garshol.duke.Duke

      

+2


source







All Articles