bentolor / idea-cli-inspector

A little command-line tool to integrate the awesome IntelliJ IDEA code inspections in your continuous integration (CI) process using Jenkins, Bamboo, et. al.
Apache License 2.0
139 stars 13 forks source link

Custom Scopes in Inspections #5

Closed ihowell closed 8 years ago

ihowell commented 8 years ago

Goals:

Leads:

bentolor commented 8 years ago

Ahhh... there it is! Last time I checked there was no such feature. This is really helpful and a much better approach over excluding analysis results as skipfile does. Using IDEA scopes can result in much faster analysis. Need to test if this works.

Good point, Ian!

ihowell commented 8 years ago

I've been working on it for a while, but the syntax for including system properties in the JVM for an executable evades me.

bentolor commented 8 years ago

I see. Following you at the issues @ JetBrains YouTrack.

I think we would prefer a solution, which accepts to pass the scope as program argument rather than modifying the idea.properties file. But I see currently you struggle at IDEA not applying the scope at all.

ihowell commented 8 years ago

Yup, if I can get it to apply in idea.properties, then I should be able to get it to work as an argument. It's just that first occurrence.

ihowell commented 8 years ago

Do you have any ideas (haha, get it?) on how to do it at the argument level? @bentolor

bentolor commented 8 years ago

According to the launcher script rather no unless we could abuse $AGENT.

I really wonder why this is not just a simple addon-parameter as all other parameters are, too. So I'd probably rather go with a pull-request fixing that in IntelliJ itself.

Until then it seems that we'd need to resort to a nasty idea.vmoptions file hack. I think this would be rather hard, because the IDEA scripts contain platform-dependent placeholders & names all over which make the whole thing a guess'n'try approach.

ihowell commented 8 years ago

Turns out the hack needs to be done with idea.properties, which makes it a little easier, at least I got it working.