There are lots of ways to contribute to Uncrustify:
- Report Issues
- Propose Features or Improvements
- Submit Pull Requests
- Pull latest master and create a new branch:
- Branch name should use lowercase, using
-
to separate words and not_
. Other special characters should be avoided. - A hierarchical structure can be designated using
/
(e.g.area/topic
). The last part of the name can be keywords likebugfix
,feature
,optim
,docs
,refactor
,test
, etc. - Branches should be named after what the change is about
- Branches should not be named after the issue number, developer name, etc.
- Branch name should use lowercase, using
- Organize your work:
- Specialize your branch to target only one thing. Split your work in multiple branches if necessary
- Make commits of logical units
- Try to write a quality commit message:
- Separate subject line from body with a blank line
- Limit subject line to 50 characters
- Capitalize the subject line
- Do not end the subject line with a period
- Use imperative present tense in the subject line. A proper subject can complete the sentence If applied, this commit will, [subject].
- Wrap the body at 72 characters
- Include motivation for the change and contrast its implementation with previous behavior. Explain the what and why instead of how.
- Definition of done:
- The code is clean and documented where needed
- The change has to be complete (no upcoming fix-up commits)
- The change should always be accompanied by regression tests (explain why if not possible)
- Preparing a Pull Request (PR):
- To reduce the likelihood of conflicts and test failures, try to avoid merges, rebasing your work on top of latest master before creating a PR
- Verify that your code is properly formatted by running
scripts/Run_uncrustify_for_sources
- The PR title should represent what is being changed (a rephrasing of the branch name if set correctly)
- The PR description should document the why the change needed to be done and not how which should be obvious by doing the code review