loading...

Discussion on: Do your commits pass this simple test?

Collapse
philoserf profile image
Mår Ekkertsen

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.

Collapse
sublimegeek profile image
Jonathan Irvin Author

What's the point of squashing?

Collapse
philoserf profile image
Mår Ekkertsen

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.

Collapse
theodesp profile image
Theofanis Despoudis

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.

Collapse
philoserf profile image
Mår Ekkertsen

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.

Thread Thread
sublimegeek profile image
Jonathan Irvin Author

Had to look that up. For those unfamiliar: git push --force-with-lease