Commit your changes in logical chunks. For any Git project, some good rules for commit messages are
* The first line is commit summary, 50 characters or less,
* Followed by an empty line
* Followed by an explanation of the commit, wrapped to 72 characters.
* See a note about git commit messages for more.
The first line of a commit message becomes the title of a pull request on GitHub, like the subject line of an email. Including the key info in the first line will help us respond faster to your pull.
If your pull request has multiple commits which revise the same lines of code, it is better to squash those commits together into one logical unit. Learn from here How to squash commits But you don't always have to squash — it is fine for a pull request to contain multiple commits when there is a logical reason for the separation.