Marc Rufer bio photo

Marc Rufer

Software engineer
@d-fens GmbH

Twitter LinkedIn Github Stackoverflow
RSS Feed

IntelliJ - Setup custom inspection profiles

Marc Rufer 07 Apr 2015 inspection-profiles IntelliJ IDEA JetBrains

In most java projects I worked, compiling the source code in an IDE produced lots of warnings. Figure out which warnings could be ignored is very troublesome. In this blog post I will show you how to set up project specific inspection profiles in IntelliJ to avoid the output of ignorable warnings.

What’s an inspection profile?

An inspection profile defines which inspection rules are enabled/disabled and the rules severity level. In other words inspection profiles define which types of problems should be logged through code inspection.

Create a new inspection profile

Creation of a new inspection profile is described under Customizing Profiles @IDEA documentation. As mentioned in the documentation the new profile is created as a copy of the default profile.

To set the newly created profile as a project specific inspection profile check share to team members as shown below

IntelliJ IDEA screenshot

In this case the profile is saved in XML-format under PROJECT_ROOT/.idea/inspectionProfiles.

Customize inspections profiles

Now the newly created profile can be adjusted according your wishes.

IntelliJ allows you to suppress certain inspections for a specific peace of code or for a whole file. Suppressing inspections can be done either from the editor or from the inspection tool window. More details about suppressing inspections in detail can be found under Suppressing inspections @IDEA documentation. I recommend to suppress all warnings, which could be ignored by developers, so that only warnings that have to be fixed will be printed out after inspection.

comments powered by Disqus


HOWTO Access Azure File Share in PowerShell Script executed by a Scheduled Task BUG "Task Scheduler service is not available" Error, if specifying Network Connection Condition HOWTO Sync OneDrive on Server even if Windows User not logged in HOWTO Access Microsoft Access Database with PowerShell Get NetworkCredential from PSCredential splits Username into Username and Domain HOWTO Create LocalDB File (.mdf) manually in Visual Studio 2015 HOWTO Set Cookie Header on DefaultRequestHeaders of HttpClient HOWTO Set up PowerShell Remote Session Configuration HOWTO Analyze PowerShell Scripts with PSScriptAnalyzer HOWTO Sign PDF with SuisseID NoBrainer PUT/PATCH/MERGE with OData Service Client Apply Commit from one Repository to another GitHub Repository creation with PowerShell HOWTO Sign PowerShell Script with SuisseID Swissunihockey game schedule PDF generator HOWTO Maven Release on JetBrains TeamCity Limitations when running Activiti in H2 Embedded Mode HOWTO Pylint Integration in IntelliJ 14 HOWTO Install Windows 10 IoT Core on Raspberry PI 2 from a VM First steps with Dropwizard Allman code style for IntelliJ First steps with Flyway IntelliJ - Setup custom inspection profiles Configuration properties meta-data support in IntelliJ AMQP Integration with spring integration OCA Java SE 7 Programmer I Certification Guide Swissunihockey key matcher Swisscom SMS-API-Client Some hints concerning logging with Log4j IFTTT A brilliant service Run deltacloud on a VirtualBox-VM Project specific maven settings in IntelliJ AngularJS Javascript for beginners Liferay in Action