Search code examples
eclipsejarexportwarbuildpath

How to mark .jar file as excluded from publish/export structure?


I have a .war project in Eclipse. It is probably not relevant but I should mention that it was converted from a maven project using mvn eclipse:eclipse plugin.

I saw a warning that various .jar files on the Build Path were not being exported. To fix this I went to Project Properties -> Deployment Assembly and added the jars that needed to go into the .war

However, one .jar file does not need to go into the .war because it will be provided by the container. It is on the build path merely to get the project to compile.

For this .jar file, I want to get rid of the warning. One way was to Ctrl+1 to QuickFix which caused the Properties->Java Build Path->Libraries tab->...jar file to have an extra line on expanding it which says: Excluded from publish/export structure: (None)

My question is how could I have done this without Quick Fix? I could not find any way to exclude from publish/export structure without using the Eclipse Ctrl+1 Quick Fix.


Solution

  • There is no other UI beyond the quick fix for setting the ignore flag.