re: Do your commits pass this simple test? VIEW POST


I’ve been thinking about the complete git/GitHub workflow.

  1. Working commits as described here.
  2. Squashing and reorganizing the history in preparation for a pull request.
  3. What to include in a pull request and what to move to another pull request.

Thanks for prompting my thoughts again.


Squashing is about organizing. The most common case are putting a few commits that do very similar things together as one for the final history.


I suppose the second point makes sense if you are creating specialized branches or when you are working locally and before you push your changes you want to show a unified picture in your log.


It is actually part of a common workflow with GitHub. Commit locally often. Push to a working branch on a personal fork often. Reorganize, squash, rebase, locally then git push --force-with-lease the result you want in a pull request onto your branch before sending it back to the parent project.

code of conduct - report abuse