3 ms·
I went to the other extreme. I have a somewhat elaborate fish function which detects any use of -a and refuses to call Git with it. I had gotten lazy about goo
by samatman 2y ago
I went to the other extreme. I have a somewhat elaborate fish function which detects any use of -a and refuses to call Git with it.
I had gotten lazy about good commits, basically, `git commit -a` was in my muscle memory. Forcing myself to treat staging as a step before committing, and getting in the habit of using `git add -p` when called for, has made a meaningful difference in the quality of my commit history.
If one is disciplined about making changes in the first place, I suppose this matters less. But I'm not, and also don't want to be: if I spot something else which needs doing while I'm in flow mode, I'm not going to put it off just to keep commits nice, not when there are better options for doing that part.
- deleted 2y ago[deleted]
- alkonaut 2y agoI make one elaborate commit where I carefully stage things etc. But invariably I miss something, find 3 typos and so on. that’s when the aliases are handy. The alias for fixing a typo is using all, amend and no-edit. Super useful. But obviously needs to be used with care when you only do such a fix. I’d be perfectly happy for my git oops to refuse running if there is more than one changed line to commit, for example.
- deleted 2y ago[deleted]