ux (Housing) issues
Other tags in Housing
Raise real-world problems, find people facing the same issue, and discuss solutions.3,000 issues0 comments
ux (Housing)
⭐️ Lean Branching - a git branching model to keep clean history
We are thinking about adding to Fork a feature which would help teams to keep clean history. As you know it's pretty difficult to have a clean history in git. I've got some ideas and tricks how that can be achieved. Briefly: create a separate branch for each feature, synchronize your changes with the `main` branch using rebase and merge back to `main` at the end. My point of view is similar to what Chris Manson suggests in his great article (https://simplabs.com/blog/2021/05/26/keeping-a-clean-git-history/, I really recommend to read it if you haven't yet). Here's an example of a decent git history: <img width="363" alt="Screenshot 2022-01-20 at 15 58 13" src="https://user-images.githubusercontent.com/618115/150363469-2502c474-faa4-456c-b698-cea9d361e802.png"> The commit history may look simple and clear, but making it so is surprisingly difficult and requires the use of some advanced (and dangerous) git features. In particular: - rebase (to rebase on `main`) - force push with lease (to update the remote tracking reference after the rebase) - hard reset (if something went wrong and we want to start from scratch). We are thinking about adding to Fork the ability to easily make those operations and perform dangerous things automatically (without hiding them, though!). Something like git-flow, but not so complicated and with a dedicated `sync` option. We called it "Lean branching" trying to reflect the approach but may be there could be a better name. Goals: - Be simple
Comments (0)
No comments yet. Start the discussion.