If you discover issues, have ideas for improvements or new features, please report them to the issue tracker of the repository or submit a pull request. Please, try to follow these guidelines when you do so.
- Check that the issue has not already been reported.
- Check that the issue has not already been fixed in the latest code
(a.k.a.
master
). - Be clear, concise and precise in your description of the problem.
- Open an issue with a descriptive title and a summary in grammatically correct, complete sentences.
- Include the output of
rubocop -V
:
$ rubocop -V
0.50.0 (using Parser 2.4.0.0, running on ruby 2.4.2 x86_64-linux)
- Include any relevant code to the issue summary.
- Read how to properly contribute to open source projects on GitHub.
- Fork the project.
- Use a topic/feature branch to easily amend a pull request later, if necessary.
- Write good commit messages.
- Use the same coding conventions as the rest of the project.
- Commit and push until you are happy with your contribution.
- If your change has a corresponding open GitHub issue, prefix the commit message with
[Fix #github-issue-number]
. - Make sure to add tests for it. This is important so I don't break it in a future version unintentionally.
- Add an entry to the Changelog by creating a file
changelog/{type}_{some_description}.md
. See changelog entry format. - Please try not to mess with the Rakefile, version, or history. If you want to have your own version, or is otherwise necessary, that is fine, but please isolate to its own commit so I can cherry-pick around it.
- Make sure the test suite is passing and the code you wrote doesn't produce
RuboCop offenses (usually this is as simple as running
bundle exec rake
). - Squash related commits together.
- Open a pull request that relates to only one subject with a clear title and description in grammatically correct, complete sentences.
Here are a few examples:
* [#716](https://github.com/rubocop/rubocop-ast/issues/716): Fixed a regression in the auto-correction logic of `MethodDefParentheses`. ([@bbatsov][])
* New cop `ElseLayout` checks for odd arrangement of code in the `else` branch of a conditional expression. ([@bbatsov][])
* [#7542](https://github.com/rubocop/rubocop-ast/pull/7542): **(Breaking)** Move `LineLength` cop from `Metrics` department to `Layout` department. ([@koic][])
- Create one file
changelog/{type}_{some_description}.md
, wheretype
isnew
(New feature),fix
orchange
, andsome_description
is unique to avoid conflicts. - Mark it up in Markdown syntax.
- The entry line should start with
*
(an asterisk and a space). - If the change has a related GitHub issue (e.g. a bug fix for a reported issue), put a link to the issue as
[#123](https://github.com/rubocop/rubocop-ast/issues/123):
. - Describe the brief of the change. The sentence should end with a punctuation.
- If this is a breaking change, mark it with
**(Breaking)**
. - At the end of the entry, add an implicit link to your GitHub user page as
([@username][])
. - The rake tasks
rake changelog:new|bug|change
will create a file with the body based off the last git commit. Modify it and add it to your commit; maintainers will merge it automatically later. - Alternatively, you may modify the CHANGELOG file directly, but this may result in conflicts later on. Also, if this is your first contribution to RuboCop project, you'll have to add a link definition for the implicit link to the bottom of the changelog as
[@username]: https://github.com/username
.