stefan-kaestle / openhab2-addons

Add-ons for openHAB 2.x
Eclipse Public License 2.0
16 stars 1 forks source link

Ran mvn spotless:apply to apply correct code formatting #18

Closed coeing closed 4 years ago

coeing commented 4 years ago

To match the openHAB guidelines about code formatting I ran the Maven Spotless command mvn spotless:apply as suggested here: https://www.openhab.org/docs/developer/guidelines.html#code-format

Now mvn spotless:check -Dspotless.check.skip=false doesn't report any errors.

This fixes source files and XML files as well, so two tasks of #16 with one pull request 🎉

GerdZanker commented 4 years ago

Would be nice, if I can merge pr #11 before this to avoid merge conflicts. I hope rerunning the Maven Spotless command on new code is simple.

GerdZanker commented 4 years ago

My pr is merged and causing conflicts. Can you @coeing rebase your branch and run mvn spotless again to format my new code too?

coeing commented 4 years ago

@GerdZanker Yes, sure, no problem. It was pretty quickly done :)

coeing commented 4 years ago

Just rebased my branch and ran spotless:apply again.

@GerdZanker @stefan-kaestle Please make sure to make some basic adjustments to your IDE:

Those are the main things. But it should be enough to run the command once before merging a branch. The settings for the indents would be most important as it changes the biggest number of lines.