0

I got a bunch of java files that I don't want to be compiled as part of the module. Is there a way to tell intellij to ignore them?

JRR
  • 5,694
  • 5
  • 35
  • 57
  • If you are using Maven, you can use the compiler plugin: https://stackoverflow.com/questions/17920920/maven-excluding-java-files-in-compilation – Héctor Sep 04 '17 at 06:15
  • I'd rather ask myself: why do I add Java source files in the directory supposed to contain all Java source files that must be compiled if I don't want them to be compiled? Why don't you just delete those files? Or put them somewhere else? What are these source files for? – JB Nizet Sep 04 '17 at 06:25

1 Answers1

0

Under Settings > Compiler > Excludes, add an entry.

Source: Intellij exclude file from being compiled

Jeffrey Ram
  • 380
  • 2
  • 8
  • thanks. I am using the second method on the page you linked as your suggested one didn't seem to work. – JRR Sep 04 '17 at 06:33