3

I followed the instructions in this response: https://stackoverflow.com/a/35273850/1122470

However, after using the automatic formatting CtrlShiftAltL, the code was reformatted for sure, yes, but I am not sure if it was according to the checkstyle.xml

When I try to check for violations using gradlew checkstyle all the previous errors seem to remain.

Any suggestions on how to get the formatting done according to the checkstyle rules using the plugin?

Edit: adding config screenshots

enter image description here

Codestyle settings

8
  • are both (idea and gradle) using the same checkstyle config? Commented Oct 27, 2018 at 8:16
  • yes! both are using the same config file Commented Oct 27, 2018 at 8:31
  • Try to press ctrl+shift+a and type checkstyle - there should be actions related to checkstyle plugin. Commented Oct 27, 2018 at 8:33
  • So have you imported checkstyle config and doesn't see it is applied? (latest IDEA import location: duaw26jehqd4r.cloudfront.net/items/263S3o3U0m1J2f3z200k/…). You should set the rule which will say for sure, was it applied or not, as you're not sure it works. Commented Oct 27, 2018 at 8:43
  • @extempl Please check the updated question (I added the screenshots) and please confirm if that is what you meant! If so, I have applied the configurations Commented Oct 27, 2018 at 9:15

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.