3 ms·
I’m all for staying flexible and realizing the rule isn’t absolute, but fixing a typo or improving a commit is a very low bar. On my teams, I reserve rebase on
by dahart 7y ago
I’m all for staying flexible and realizing the rule isn’t absolute, but fixing a typo or improving a commit is a very low bar. On my teams, I reserve rebase on public history for more serious emergencies, like someone accidentally checking in security keys.
It’s probably fine on a very small team, but pull with rebase doesn’t protect you from merge conflicts when someone rebases master underneath you, this is why the practice of rebasing public history is and should generally be considered an anti-pattern.
- kevsim 7y agoI get your point, but checking in security keys is cause to rotate keys, not to rebase and force push.
- dahart 7y ago100% absolutely agreed if the keys were accidentally made public outside the org. If not, rotating keys is sometimes a bit more work than a quick rebase & push. It was the best example of an exception to the rule I could think about, but personally, my threshold for whether rebasing master is ever allowed might be closer to 'no if team is larger than 3 people, otherwise try not to, think twice, and ask everyone first.'