The code assumes files are created in a package called regexapp, with entry point = regexapp.TestRegex. I want a single jar file, with no nested jar files, to include all class, doc, and source files. I also want this jar file to be runnable. The only way that I have found to create the directory structure that I want is to execute the following in Dos, from the <parent dir>:
jar -cf TestRegex.jar *.* <or jar -cmf Manifest.txt TestRegex.jar *.*>
To make it runnable (via java -jar ...), I need a manifest file with an entry like: Main-Class: regexapp.TestRegex
But, if I create the jar file from the <parent dir>/class directory, I won't get the directory structure that I want. Instead, if I create it from the <parent dir>, how do I specify (in the manifest):
1. The main class? 2. The fact that the executable class path INSIDE the jar file should be <parent dir>/class?
Apparently, the manifest entry for Class-Path is not relevant, since that seems to apply to the location of files EXTERNAL to the jar. Apparently, what I want is not doable. Comments?
Assuming that it is not doable, how is this situation typically treated? Should I create three separate jar files (class.jar, source.jar, docs.jar)? If so, do I then package them into one superordinate jar file, or is a zip file more routine?
What type of email attachment will please the job interviewer? Will both methods in above paragraph force interviewer to unpack the zip/jar file and then run the (nested) class.jar?