Thursday, 15 March 2007

JAR Manifest File Agony

Everyone will tell you to finish off the last line of a JAR manifest file with a newline.

What they don't tell you is that if you use the Main-Class directive, then do not have any whitespace at the end of that line.

The JAR File reader includes this whitespace as part of the name of the main class.

You know you have this problem when you seen the NoClassDefFoundError/Exception whatever.

No comments: