- Write meaningful and concise commit message:
- ❌ "Add new feature"
- ✅ Changing X and Y because of Z
- Follow a pattern / convention for commit messages. You can check a good reference here.
- Squash commits you did for testing / adding small changes. You can check how to do that here.
- Separate your commits into isolated units of "atomic" changes. Examples:
- Changes in one class / file
- Refactor previous to the actual change you'll be doing
- Changes in one function if the change is considerable
- Changes that different people could review (you can point the reviewer to just one commit)
- If you have an integration with a ticket system (like Shortcut or JIRA), you can normally include a reference to the ticket to make the binding between ticket and commit.
Last active
October 18, 2022 14:59
-
-
Save bruno-uy/b3f41e941ee9ae928102ea11687f2478 to your computer and use it in GitHub Desktop.
Git good practices
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment