angularjs - How to tidy up a git branch / pull request full of unintended commits? -


i casual contributor angular.js project.

months ago, created new feature branch in local repo test enhancement, , when happy it, sent pull request. there problems however, , never did acceptable state (though did find the issue blocking me).

recently, revisited branch hoping fix up. tried bring local repo date using github windows, in doing mucked branch quite bit: local branch contains hundreds of commits upstream repo, , worst of original (abandoned) pull request includes these commits! in, "jamesdaily referenced issue commit in jamesdaily/angular.js 4 months ago" on many different issues.

i've since brought local master date via these commands.

but goal remove clutter i've caused main angular/angular.js repo. i'm willing take whatever actions necessary. have no outstanding changes care retain in local repo.

how can tidy up?

here branch in question: https://github.com/jamesdaily/angular.js/tree/deeplinking-hash-url-fix

and mucked pull request: https://github.com/angular/angular.js/pull/4191

here example issue branch leaving notes everywhere: https://github.com/angular/angular.js/issues/5247

create new branch @ point want start (keep original backup, until long after satisfied nothing broke).

use git cherry-pick changes want new branch. afterwards can go in , clean git rebase --interactive, allows squash commits together, split them, edit them, reorder them, ... in general go wild. make sure commits in mangled history make sense, , declare cleaned version official.


Comments

Popular posts from this blog

javascript - jquery or ashx not working -

opencv - DataType<cv::detail::deriv_type>::depth what is it used for -

python 3.x - Mapping specific letters onto a list of words -