github - In Git, how can I reorder (changes from) pushed commits? -


i have repository single (master) branch:

a > b > e > f > g > c > d 

it turns out need changes in c , d (two commits toward end of history far) occur earlier, i’d have:

a > b > c > d > e > f > g 

everything’s been pushed. understand i’m not supposed rebase pushed commits, can do?

here's quick , dirty solution doesn't change history:

  1. use git revert remove each commit branch.
  2. use git cherry-pick reapply commits in order want.

push these changes. lets change order of commits without changing history.


Comments

Popular posts from this blog

html - Outlook 2010 Anchor (url/address/link) -

javascript - Why does running this loop 9 times take 100x longer than running it 8 times? -

Getting gateway time-out Rails app with Nginx + Puma running on Digital Ocean -