2022-03-20 12:35:43 +00:00
|
|
|
# Contributing to TFM 4.3 Reloaded #
|
2013-06-11 15:59:04 +00:00
|
|
|
|
2022-03-31 01:21:24 +00:00
|
|
|
TFM 4.3 Reloaded is a CraftBukkit server plugin designed primarily to support legacy TotalFreedom
|
|
|
|
clones. However, it can be used in a variety of other configurations with minimal fuss.
|
|
|
|
|
|
|
|
For those who wish to contribute, we encourage you to fork the repository and submit pull requests.
|
|
|
|
Below you will find guidelines that explain this process in further detail.
|
2013-06-11 15:59:04 +00:00
|
|
|
|
2014-08-02 19:45:57 +00:00
|
|
|
## Quick Guide ##
|
2022-03-31 01:21:24 +00:00
|
|
|
|
|
|
|
1. Create or find an issue on our [Issue Tracker](https://github.com/TotalFreedom/TFM 4.3
|
|
|
|
Reloaded/issues).
|
|
|
|
2. Does your change fit TFM 4.3 Reloaded's goals?
|
2022-03-20 12:35:43 +00:00
|
|
|
3. Fork TFM 4.3 Reloaded if you haven't done so already.
|
2014-08-02 19:45:57 +00:00
|
|
|
4. Make a branch dedicated to your change.
|
|
|
|
5. Make your change.
|
2014-08-02 19:53:29 +00:00
|
|
|
6. Commit your change according to the [committing guidelines](#committing-your-changes).
|
2014-08-02 19:45:57 +00:00
|
|
|
7. Push your branch and submit a pull request.
|
|
|
|
|
2013-07-11 12:18:10 +00:00
|
|
|
## Getting Started ##
|
2022-03-31 01:21:24 +00:00
|
|
|
|
2014-08-02 19:45:57 +00:00
|
|
|
* Search the issue tracker for your bug report or feature request.
|
|
|
|
* If the issue does not exist already, create it.
|
2022-03-31 01:21:24 +00:00
|
|
|
* Clearly describe the issue.
|
|
|
|
* If your issue is a bug, describe the steps needed to reproduce it.
|
|
|
|
* If your issue is a feature request, ensure it fits TFM 4.3 Reloaded's goals and describe your
|
|
|
|
feature in detail.
|
2014-08-02 19:45:57 +00:00
|
|
|
* Fork the repository on GitHub.
|
|
|
|
|
2022-03-20 12:35:43 +00:00
|
|
|
## Does the change fit TFM 4.3 Reloaded's goals? ##
|
2014-08-02 19:45:57 +00:00
|
|
|
|
2022-03-31 01:21:24 +00:00
|
|
|
As a rough guideline, ask yourself the following questions to determine if your proposed change fits
|
|
|
|
the TFM 4.3 Reloaded project's goals. Please remember that this is only a rough guideline and may or
|
|
|
|
may not reflect the definitive answer to this question.
|
2014-08-02 19:45:57 +00:00
|
|
|
|
2022-03-31 01:21:24 +00:00
|
|
|
* Is the change in line with the principles of "Total Freedom"? TotalFreedom is a freedom-based
|
|
|
|
server. We don't normally make changes that restrict players unless absolutely necessary.
|
2014-08-02 19:45:57 +00:00
|
|
|
|
2022-03-31 01:21:24 +00:00
|
|
|
* Is the change directed towards the TotalFreedom server? Changes must be directed towards the
|
|
|
|
TotalFreedom server. Changes such as adding ranks, adding the name of other TotalFreedom-like
|
|
|
|
servers will not likely be accepted.
|
2014-08-02 19:45:57 +00:00
|
|
|
|
2022-03-31 01:21:24 +00:00
|
|
|
* Does the change add a feature that involves micromanagement? Pull requests that involve adding a
|
|
|
|
micromanagement feature will likely not be accepted. This includes shorthands for multiple
|
|
|
|
commands.
|
|
|
|
|
|
|
|
* Is a similar feature already present? Features that have very similar alternatives will not be
|
|
|
|
added. For example: A command that temporarily bans a player from the server is very similar to
|
|
|
|
the _/tban_ command and thus will likely not be accepted.
|
2013-06-11 15:59:04 +00:00
|
|
|
|
2013-07-11 12:18:10 +00:00
|
|
|
## Making Changes ##
|
2022-03-31 01:21:24 +00:00
|
|
|
|
2013-06-11 15:59:04 +00:00
|
|
|
* Create a topic branch from where you want to base your work.
|
2022-03-31 01:21:24 +00:00
|
|
|
* This is usually the master branch.
|
|
|
|
* Name your branch something relevant to the change you are going to make.
|
|
|
|
* To quickly create a topic branch based on master, use `git checkout master` followed
|
|
|
|
by `git checkout -b <name>`. Avoid working directly on the `master` branch.
|
2014-08-02 19:53:29 +00:00
|
|
|
* Make sure your change meets our [code requirements](#code-requirements).
|
2014-08-02 19:45:57 +00:00
|
|
|
|
|
|
|
### Code requirements ###
|
2022-03-31 01:21:24 +00:00
|
|
|
|
|
|
|
* Code must be written in [Google style](https://google.github.io/styleguide/javaguide.html), and
|
|
|
|
that it
|
|
|
|
follows [Java Code Conventions](http://www.oracle.com/technetwork/java/codeconventions-150003.pdf)
|
|
|
|
.__
|
|
|
|
* No spaces, use 4 tabs for indentation.
|
2014-08-02 19:45:57 +00:00
|
|
|
* No trailing whitespaces for code lines, comments or configuration files.
|
|
|
|
* No 80 character line limit or 'weird' midstatement newlines.
|
|
|
|
* Additions should be compiled, complete and tested before committing.
|
2022-03-31 01:21:24 +00:00
|
|
|
* Avoid using `org.bukkit.Server.dispatchCommand()`. Commits that make use of it will likely be
|
|
|
|
rejected.
|
2014-08-02 19:45:57 +00:00
|
|
|
* Files must always end with a newline.
|
|
|
|
* Avoid nested code structures.
|
2022-03-31 01:21:24 +00:00
|
|
|
* Avoid poor code.
|
2014-08-02 19:45:57 +00:00
|
|
|
|
|
|
|
## Committing your changes ##
|
2022-03-31 01:21:24 +00:00
|
|
|
|
2013-06-11 15:59:04 +00:00
|
|
|
* Check for unnecessary whitespace with `git diff --check` before committing.
|
2014-08-02 19:45:57 +00:00
|
|
|
* Describe your changes in the commit description.
|
|
|
|
* For a prolonged description, continue on a new line.
|
|
|
|
* The first description line should be once sentence and should not exceed 10 words.
|
|
|
|
* The first description line should contain either:
|
2022-03-31 01:21:24 +00:00
|
|
|
* For a bug-related issue: "Resolves _#issue_".
|
|
|
|
* For a feature request: "Fixes _#issue_".
|
|
|
|
* "#issue" is the issue number number you based your work on.
|
2013-06-11 15:59:04 +00:00
|
|
|
|
2014-08-02 19:45:57 +00:00
|
|
|
#### Example commit message ####
|
2022-03-31 01:21:24 +00:00
|
|
|
|
2014-08-02 19:56:59 +00:00
|
|
|
```
|
|
|
|
Fixed bugs with /saconfig clear. Resolves #167
|
|
|
|
Admins can now use /saconfig clear [ip] to remove the designated IP (only their own IPs can be removed.
|
|
|
|
They can also simply use /saconfig clear to remove all IPs but the current one. /saconfig clear is safe,
|
|
|
|
meaning you can't remove your current IP or an IP that doesn't belong to you.
|
|
|
|
```
|
2013-06-11 15:59:04 +00:00
|
|
|
|
2013-07-11 12:18:10 +00:00
|
|
|
## Submitting Your Changes ##
|
2022-03-31 01:21:24 +00:00
|
|
|
|
2014-08-02 19:45:57 +00:00
|
|
|
* Push your changes to the topic branch in your fork of the repository.
|
2013-06-11 15:59:04 +00:00
|
|
|
* Submit a pull request to this repository.
|
2022-03-31 01:21:24 +00:00
|
|
|
* Explain in detail what each one of your commits changes and point out any big changes.
|
2013-06-11 15:59:04 +00:00
|
|
|
* Wait as a developer evaluates your changes.
|
2014-08-02 19:45:57 +00:00
|
|
|
* Do not add any prefixes or tags.
|
|
|
|
|
|
|
|
## Tips - How To Get Your Pull Request Accepted ##
|
2022-03-31 01:21:24 +00:00
|
|
|
|
|
|
|
* Please make sure your changes are written such as other features would be. For example: Commands
|
|
|
|
have their own class and extend FreedomCommand.
|
2014-08-02 19:45:57 +00:00
|
|
|
* Do not increment the version number.
|
2022-03-31 01:21:24 +00:00
|
|
|
* If you want to add multiple changes, please make one pull request per change. This way, it's
|
|
|
|
easier to accept your changes faster and won't block the other changes if there is an issue with a
|
|
|
|
specific line of code.
|
2014-08-02 19:45:57 +00:00
|
|
|
* Please avoid having to add files in the main namespace where possible.
|
2022-03-31 01:21:24 +00:00
|
|
|
* Please refrain from using an excessive amount of commits. As few as possible is generally the
|
|
|
|
best.
|
|
|
|
* Please do not spread your contribution over several pull-requests unless strictly necessary.
|
2013-06-11 15:59:04 +00:00
|
|
|
|
2013-07-11 12:18:10 +00:00
|
|
|
## Additional Resources ##
|
2022-03-31 01:21:24 +00:00
|
|
|
|
2022-03-20 12:35:43 +00:00
|
|
|
* [Bug tracker](https://github.com/TheDeus-Group/TFM-4.3-Reloaded/issues/)
|
2013-06-11 15:59:04 +00:00
|
|
|
* [General GitHub documentation](http://help.github.com/)
|
2013-06-18 14:34:35 +00:00
|
|
|
* [GitHub pull request documentation](http://help.github.com/send-pull-requests/)
|