3 ms·
… which results in either losing work sooner or later (because you don't commit often and early enough to always have something to roll back to), or pollutes hi
by 5e92cb50239222b 4y ago
… which results in either losing work sooner or later (because you don't commit often and early enough to always have something to roll back to), or pollutes history with junk WIP commits and merges. Maybe this is because I am not a "normal developer" (more like below normal), but this "overcomplication" both produces a clean and easy to read history (that is also easy to bisect when anything goes wrong and you need to find the offending commit), and also saved my bacon countless times.
- ilyt 4y ago> … which results in either losing work sooner or later (because you don't commit often and early enough to always have something to roll back to), You can just git add without commit. The changes will be saved to index and live till git decides to GC its files (so few months). Extracting those might be PITA (as requires playing with more arcane git commands) but you can't really lose data git stash is also lifesaver if you need to quickly jump to branch to do something else Lastly there is "git commit --amend" way of just incrementally changing the current commit but that requires some self-discipline (or hooks preventing your from) to not amend pushed commit and then having to fix that.