-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
contribution guidelines #159
base: master
Are you sure you want to change the base?
contribution guidelines #159
Conversation
through trial and error i settled on the there is a the default formatter settings for edit: i meant the package target not publish |
Love the initiative, thanks for your help. Just laying in on a few points:
|
I use IntelliJ IDEA for Java projects, and all my settings are stored In my global settings.
As for the Java formatting the main points I would include are
As for other rules I use most of the ones built into IntelliJ and the SonarLint plugin. Kotlin - I'd rather have normal Java instead |
for a bit of context, I technically only started using Java last month for this project. the last time I used it was like a decade ago and even then not that much. I spend essentially all my time with C++ lets start with the Java version whether or not to upgrade the used Java version is something that should probably be discussed separately for this I was mostly interested in adding a bit of information on why exactly an old Java version is needed to support old Minecraft versions but best I found was this comment about specific spigot versions |
Java IDEs that come to mind are
all of them can be used for free for code formatting we could use the however, in testing there are still some differences between formatting with IntelliJ and VSCode when using a style defined with an eclipse xml see here whether or not the difference can be eliminated requires some more investigation |
Another thing you could add is testing requirements for testing their changes should be tested against the latest normally used Java version (17 currently) and on the latest release of Minecraft for each platform (when multi-platform support is added) java 17 and paper 1.20.4 is how I'm currently testing my changes |
ok, before this auto formatting stuff is driving me insane I will settle on a good enough solution: https://github.com/revelc/formatter-maven-plugin configured to automatically run on compile my other attempts with other IDE plugins always resulted in differences between the IDEs that I could not work out the maven plugin approach ensures 'consistent' formatting between IDEs and can also be used to validate formatting during CI runs one thing I noticed was that all the formatters are keeping custom line breaks, if it does not conflict with other format rules also, newer version of the plugin require jdk versions above 8 see here let me know if this approach is acceptable |
If formatting is going to be a huge pain to do automatically then just a list of formatting rules should suffice. Worse case we may have to fix some of it ourselves before or after merging the PR. |
well, it was only a pain to find something that works across IDEs (I hope that I just did something wrong, doesnt seem like the thing that should be complicated). as for the jdk requirement, that is only for the developers, so that the formatter plugin can run. |
# resolved conflicts: README.md
for the style guide there are two options, writing a new one or using an existing one from the ones I looked at I liked the (old?)twitter one here |
this resolves #158 by adding a CONTRIBUTING.md file that briefly explains how to contribute to the project
currently only a draft as it is unfinished