Rajat Gupta
Rajat Gupta

Reputation: 26587

Prevent compiling a package from amongst several packages in a netbeans project

How to prevent compiling a package from amongst several packages in a netbeans based web app project?

Actually there are certain classes within that package that are uncompilable & they actually are responsible for not any of the other packages in project, making it to ../target/classes/ folder. While building the project I saw that the packages were compiled however there are no class files in the ../target/classes/ folder. However if I remove the uncompilable package, all the other packages successfully make it to ../target/classes/ folder.

Upvotes: 0

Views: 885

Answers (2)

user330315
user330315

Reputation:

This is covered in the NetBeans FAQ in the question: "Can I exclude some classes or packages from compilation"

  • Goto Project Properties
  • Select the "Sources" node in the left hand tree
  • Click on Include/Excludes in the lower left corner
  • Specify which files to exclude in the lower input field.

Upvotes: 5

sethu
sethu

Reputation: 8411

I dont about netbeans.. but in eclipse you an add an exclusion filter on the src directory. I am pretty sure you could do the same in netbeans too. And I think netbeans creates ant build file for the project, you could try modifying that file.

Upvotes: 0

Related Questions