rebase - Is git rebasing the wrong branch? -


i have 3 branches:

master dev feature 

my branch master date. want rebase branch feature master

git checkout feature git rebase master 

but @ beginning see:

first, rewinding head replay work on top of it... applying: ajout model widget desc + stats using index info reconstruct base tree... 

ajout model widget desc + stats first commit on branch. rebase using wrong version of branch.

the result lot of conflits, , file have committed gone.

exemple :

<<<<<<< head             $this->createwidget('samples/footer','content', array('channeltitle'=>$channeltitle)); =======             $this->createwidget('samples/desc','desc', array('channeltitle' => $channeltitle));             $this->createwidget('samples/statistics','statistics', array('channeltitle' => $channeltitle));             $this->createwidget('samples/footer','footer'); >>>>>>> ajout model widget desc + stats 

he want rebase head of branch master wrong commit...(ajout model widget desc + stats)

i searched solution rebase branch lastest commit.

| * fac92fe (head, origin/feature, feature) work better | * a366488 works in ajax ! | * f5d120e appel ajax dans la vue | * c1f8360 ajout model ajax bestvide, featuredchannel (no cache active) | * 211fda0 ajout widget network | * 4d1c2a5 social link | * c511472 ajout model widget desc + stats |/ | *   2f8ddcc (origin/master, origin/head, master) merge branch 'dev' | |\ |/ / | * 0c859da dev channel/network + fix artifice |/ | * 41c0cfb (origin/update_channel, update_channel) update | * 66015b6 ajout bannerimg | * 1433e90 ajout entete script | * 619d850 ajout dossiet script crontab | * 8c4b2c8 channel inactive + simplification | * 37c453c modif network | * b764ddb fisrt version script update_channel |/ *   5676028 merge branch 'generalmodels' |\ | * da10f84 return json in utf8 | * 10f7897 job bro | * 3eadddc config grunt : 

it doesn't wrong.

your output expected

  1. first rewind commits feature
  2. then apply commits master. cannot fail , gives no particular output.
  3. then apply commits, in order, starting ajout...

in case gives conflicts. it's not unusual need resolve them in editor of choice, continue rebase. in current state rest of commits still waiting applied, not missing.

  1. fix conflicts. files run git add <file name>
  2. then git rebase --continue
  3. do until rebase complete.

if feels havoc can abort rebase git rebase --abort


Comments

Popular posts from this blog

c++ - How to add Crypto++ library to Qt project -

jQuery Mobile app not scrolling in Firefox -

How to use vim as editor in Matlab GUI -