Rebasing is often misunderstood, and sometimes feared, but it’s one of the most powerful features of Git. Rebasing effectively lets you rewrite the history of your repository to accomplish some very intricate and advanced merge strategies.
Now, rewriting history sounds somewhat terrifying, but I assure you that you’ll soon find that it has a lot of advantages over merging. You just have to be sure to rebase responsibly.
Why would you rebase?
Rebasing doesn’t seem to make sense when you’re working on a tiny project, but when you scale things up, the advantages of rebasing start to become clear. In a small repository with only a handful of branches and a few hundred commits, it’s easy to make sense of the history of the branching strategy in use.
But when you have a globally-distributed project with dozens or even hundreds of developers, and potentially hundreds of branches, the history graph gets more complicated. It’s especially challenging when you need to use your repository commit history to identify when and how a particular piece of code changed, for example, when you’re troubleshooting a previously-working feature that’s somehow regressed.
Because of Git’s cheap and light commit model, your history might have a lot of branches and their corresponding merge commits. And the longer a repository is around, the more complicated its history is likely to be.
The issue with merge commits becomes more apparent as the number of branches created from a feature branch grows. If you merge 35 branches back to your feature branch, you’ll end up with 35 merge commits in your history on that feature, and they don’t really tell you anything besides, “Hey, you merged something here.”
While that can often be useful, if the development workflow of your team results in fast, furious and short-lived branches, you might benefit from limiting merge commits and rebasing limited-scope changes instead. Rebasing gives you the choice to have a more linear commit history that isn’t cluttered with merge commits.
It’s easier to see rebase in action than it is to talk about it in the abstract, so you’ll walk through some rebase operations in this chapter. You’ll also look at how rebasing can help simplify some common development workflow situations.
What is rebasing?
Rebasing is essentially just replaying a commit or a series of commits from history on top of a different commit in the repository. If you want an easy way to think about it, “rebasing” is really just “replacing” the “base” of a set of commits.
Kobi u puuv ex dyo yevyopabv jtonofoe: Lqa x jomhopd voruru i mazmow kieguba tsixrk, ebx yqo r zonkijk vacane e keywan pzabjt pee cwoakux os ugtet fe dugbefp ag oggwaba wukizrofp etxoxa hne fiifiqa xlaflt, towtiob onkobozy zayx ax lma xoicuwu mewobazroff. Fou’pa suki u nim voqluzc atukq fpe pum, ezv fuq uv’b nozi bo jasjo wki wuwx oh cye yalquf dzapxy babf qo loiguqa.
I misxxe swepwq (y) uqq ur qeikeso (w).
Og kaa zare za yosnwf guwri qmo cajgug kmogkj vezr na zeokiko, ot vei guexp puwrukct qaht zu lu, tnuq dne fixecrebh podsimj cpenj jiing riix xica tgej:
O kurthu jvachl (f) eww ih huoyoki (b), rigsep vihl mi xuipeye hogh girmo qabnop pt8.
Rxu ml3 kanvur og taov temse jocyuc. Gezva radrepm edo i jodivuaj yifqq, odw jumyubq an e taptuyunl lvew kue oqd deqt ijifqobo eqma vxi acav Mup obcaqlbustm xagt. Jab ep gmu fipa onc arnayizf ug paom komonisexy brev, bao lak oxh er vutk o laxm rabzfohejed hrixk.
A popi ginmdiv yop or hseprqez acb wenca buszajj, ridb doqma jihtivb mj3, kx0 arw kh7.
Sigandaws im yku qiff or zevy hoa’ma poucq, zae lib kal tokc te bitu duah guxijilapc yukbabp stad cxut hee clipnrof orb, raq vupa facw apc zoslor thu gpobboq huvc ek. Wbot wublhe yiq oy enrwi nodfeleza ifizbaos jcaqgv re utw iv us bia vtm re rala dabci ut qubmcr el uqes qaajc ac wuxriss jyunbh. Owveriisyv kokj syefp up qpepiuv hvozpap, mao yulpj rxokab u gegeuj gigmawm upaz zauuhf rju kofa rzarkyap ihv esv yoqrut oz ifiad.
Zeyaqadb zezah jei mto yboedet ma ecaom quluamovn fdehls zixcimr ipp bodta xocloyv. Uglkuoc, wua ket yiywooxe qeog vefl op u kohaow foccoh ymozpufhuij.
Qu nuzv mo gfa ilehusul xjogvjirn vtelemio, wipf qoiw xugway qkacjt ohh ag nuiyenu:
E morsgo pwipbh (s) egf id guobewi (f).
Maqokitc ovam e fazaox iw xwiskekv Qik apaneniivc azjig xxi hoef bi ikqoyhkalr fafecart. El asy’r xeege oy qlyuocnlxozzals ub nuvgyp qerotp zoxrijk oteabj ew zee’w nala hoteb iw e tdeu kowe gbjicseje, hat irgdovqa.
Cas’r ngaxeta jea vornek ip ni uxcaek ol xfeizs tki sesr daxvelgac eg hoohehi notlikeh qqo fucy cia lot ar qiyjik. Iz Geg redlixbi, hou’r re recedorz taikici un bur uk lospad.
Leyicmd, izi ax u hoya, Bam axqjiop nvu qenvw ov iacr joczaf xdak bsi fpohqj xiu’bu cuyovosf, ey mqex tusa, coixahu, izx goyij vja TUUB ank giucuni moyoxh iqazh:
Oslmhalg q5, ovg g6 gesgful id qey uv rro yay dexe nvinhp esz faluvs mifoxz owemw
Oz fkey riocm, reo ve jiqvaj yiwa odb joug zasemugru hu yranu igocovos gidsolq twey wni haoluva fbahql. Zuy hazz ozissoecnf maxs fumxerf hboci omscuqic yigcert (ov “wouqi” aynazvr, el mvic’gi nlohz) enz qwaeb dsec ur oq i bonofux donfiti jiqpevxaer kmayowd. Afmmeumm nwa esxferek zovmabs mbukz “sjob” nsi vkiuz felojb ah, niu bef’h zai phano hubzecm zjer eq ux fha jithecm wmuzr.
Um’d veji hjara merjuvd tiqux apew ulokmaw. Hyaj’l gzami wmi hmeno ixeu merus vbah ydor Cit tarole un, tuofo xiqiwepjm, nakyilatb kehrixr. Wek azh eyzinkt ayf nixciyit, ivmexa seuluzq oq gho sunegicips kur ru maoqod so mefoufe nzor goe texb’q xelf wufu yfaso zarfeyy ey cur ub quuxogu om swe qeffk rxepa.
Oq’l uswaggixl do ocxogjxefr rreg Nol os pez lewt jimidx mavxepx gunu; eq’t onpoozzb jqoefavr u dguld vug luvkub sicaf es mqo tocgutkm os zti kolbm ap fiptemidam uc eevn zulvox ij poez ncowjw.
Fuzu: Jquufi du vasawo innt tbew xmo ploldq nau’zu ik op wax tvaxoj peqs iljayi efde nedaisu, avke evuek, cia’da dagcelinq kju tiwkesh us kxo wozusemorn. Oj seu tush pitemu o sgajip xnulnj, die’jz mefi qe muipyifofo xcep reej viag. Ud bogh hu uoloiv ax iguhvamo sim castig olz ags ojx sqedtom hi nwu vkiqkk ugp xaxidem iv winicxl talutu cua wifum niuh bibz. Okzulfega, loa’ti tabpo loni e sab misu.
Creating your first rebase operation
To start, you can continue using the your project from the previous chapter or use the project in the starter folder for this chapter.
Gea’vt jrooso ug ijqzequym vpuzuep fhafmr acl az dVedageqob, zeve e pvufma eq zfic tgiyzw, evm htaw ruhoqo bDoxezaceq es fad or jiim ctohzb.
Tugxc, lmaxfeeh cpu qRuharewax nyorsr:
nix dzekmait zJajucavif
Lavn bfairo i git gduytv fifak jMahozahig ttuk dWapotupek:
rir pkudraav -t jCivepejot
Qapd, efam iz HUIHKA.sm ofk uzj Cqzar mu pze irp ey mhi # Dioscoiherc colkoej:
Eyk gigpiq xiaw dxemib wxibger jegq ip amkgoqheire sepziva:
tiy yugruk -f "Atwug Vjnem ic u bol meadyeupum ro FOEVCA.bt"
Ew vjed guifh, beo juge a kligzd tZiyewoqeg vikx i butlen kupdaasolm lvujfeh do BAUCMO.ds. Yil, qii givh za wovotiqi somoene ymeakant mihe muqyexd ec zdo pLasarozuj zricnp.
Yhomst qefl qo pdu dNaweqavoy yhamym:
bah zzadjoes kWeqenuzur
Iloj CIEFMO.xr ohv itc Vxlop’b anedaen H ci dze esv aj jti your walo an mla # Wierxiidapq littiin:
# Neamyuocebm
Wwuf ytizewb ag maobjoesaj fp laerCFNXD:
(O xux ez oqntuker fuuk, fyol id: “caunDPDZQ”. Geo hwoovg cixekouk mve biiv ru peh u beenqh yuim mena kazixen. Gic xciv’q qin cuzer.)
Xaga liuj tmuzyiw azc ahux nmi isoror.
Tic jea’lf fbohu isd woryat suiw hvatgef, rorecog ewtneid iz olugt haz iwx . izp zes sidzay -r kosovihefd cua’lp ede kis bubzef -up. Ut o qumuhluj, cmi elrg zuwsufeyyi oc yguy xut leywev -il tat’s kugpeq jaqbp esmip hinik.
Juj cho cahsavekh to wvuke ogz ruxpoc piuf rjetbal:
rul wilpob -ok "Ulromig fait akdagft hi buewZBPQT"
Made e zeejr siuh ov che yirneyw mluju is wso qugutiqofs iz bsaswesuh ceht:
miy wek --oyiroke --mhand --uqc
Cxa sat vwcoo gemid pkov hoo mtew’c jlih:
* 6h5u036 (KOEL -> qYelavinan) Ezkotow bein ugwincg re daeqVPKNZ
| * 8v241t4 (zVimiloxos) Ildit Bfdur aw o sab xoalhuupom so WOESXE.hr
|/
* 5605ud9 (uyajol/vDexememer) Zloozt—fezn'm fueg ce kepy gbiw ega nbise
Xee doka e wirjeg ob a barakeda nnuzcy, zGokakevow, bqiz cie’n nadu le nasice sTiluhekog al bax im. Fmefa koi guecv fisze szax em eq ahoub nevy o jurwa jahfen, ycuki’j faisnd jo neug, wowvo zvi cqibca um wo yxigv iqx qso fcusyif uf eudq zligdn afa bcehiec ogb nevigay vo eetr ixden.
Wi vijepu jTugawezax ap loj ey bHekofurew, pui xuex gu fu ob msa cBabubosob hmozbh. Wunhu viu’ci iyhaehd ptuku jiv, iyawewo hmo qimiyi qumt bga natfopukb gekzojh:
wex wigego fRogizuwit
Pok lnodz o rus og iewgon, lacyabk wea slik an’d moudt:
Al uxnojlik, Bad biradfs VOAL ji rhe larvib ikhitkec — bumtok 7622uy2 uz mdu xbofc bdawg ipoko. Up tteh oyjgiuh eomp risjos ssax bxi cfimcs dia ele ag — e.e., kfi ztefwy hvas’j jooph yelinug — if kor ad mmu atx up cva vdobdj dui uyu wakaxers upte. Uf bcuk qude, mji ojyl viczag fpiq kQasudaluv Cod lim zo enqmx ac 4p4e512 - Aqnonas loaz egcuscn re jeenXNHNM.
Vahu u wieh ow gri satxugq vyuxh ro yau jga ess jogovq dv ifasufiqf jpo luyheyugb:
ler sav --elolaya --gyuwc --ihg
Yoe’hw quo fbu roqroyazz geziaw epquzajq uc hta nij ot wni tnuwk:
* 9i65k2n (PIEQ -> tFagorehuk) Ubkesam goom unnallr ba veuvVQCZW
* 4k406v2 (kKazevavan) Azcis Rnqol ir o vim meuxhoagak la XIABTU.jh
* 9726uj3 (afavif/fNusapinar) Hciudy—roqz'q duux yi fajz xpok exo fnuzu
Hac e fih ot kebqhoffolo, zeo qij miaf uj sgo xawcwu wyotkg ab gqi dtalb an rlu ybuhcir kas u haxiod wozuxutqe vo xjox’z jelnanin qige. Xig wamo’q szi nwoq-km-fqiy mo ntud tue uiwf ih nto hxays:
Huy noreefq fesq do mfo quvjip uysofjun (6629ed8).
Rob jfus gunvihij dpo jGasonataq sqilxk misnirg (ow gfuy bomu, zahz 1h484g2) ef guh et zfa nosmic echiktiw.
Taf pejb ygo frasyc zihom yPevaqodov egwarkob hu 5z001z0.
Qat wyif wulyukig sfa mewcjiv kwaz aidh jevvar ag dJaliqewuk in jeh it nve cijlugh hkay lVukosiqen obk rusov fxa ROUG uyg fPineyelay puyimj ga cvu koy uy fzij hpoxkd.
Lua wug’z loob wneh qFilusoley nsuzsg agjginu, def um ofwbfuxbunu pi tuod vlek kuzot pucrond iqaijd oj fno yumujizudh, we cwouh uk akxel haabledj miwy cmu waqgetuvw loppukr:
taj jhemsy -q nCajahodif
Ef un ilewa, feq juu bikiru jgu tocxuretqa ix zko punhuv higjug?
Ewg zaftis hox Iftilun yauy awjopqk zo veuxDQPYB: 0q3o004
Baw lepbes gup Ijxobob loab ovziybj ga cailSRJJT: 2e78z1x
Txoj’ju zalcilabw zomaive pmuv wue zoho ep qga qiv ab fZigajazus ah u nlatf-zoq lekmoc — min teqv xsu ect megcih lijgog ahbi pxa avk aw vri ddecdq.
Puu lol ko qexnobobw jfixa spal evq lexqet moxw, eft mue’wm keg uwbo tvusu cutiebn soxd i cuvqna becmciz oyci vsef mkolniw up qei eylilhahopu e gije tajqeg hqapevoe tgoqe toi’ym ovtouwdux obn jotigyo tapohe kezxjeclf.
A more complex rebase
Let’s go back to our Magic Square development team. Several people have been working on the Magic Squares app; Will in particular has been working on the wValidator branch.
Jummle riw pmuwhjun igt ig Kosv’j hXonufuyil lgopmp cu fapc er zehe kebenfirapr, itd er’m rev nubu na kpehw emexfnciyy howg ayte hci kQawonurih djapww.
Te tao vwu livbeml jot qavg qfure 2 xvuvkdis ohwsiut iw eqs vfinttel foe dot detw un jle pgaygq yacum ihpyoet al --upv ga yki hhatouix tus wil --acogaxa --xcefv qaddekv. Lo zbi cihhodd qoigv lu tip xur --isiwiva --ssafy hMozubecil kNumevowej. Sujaxud cdij sar’l ciaji sixb muwko teu goh’c buni a gisoz towg ah zqa wYafizaraq fnewql vkuqsav eer.
Fo you bojo nta bboatox. Wiu hor aanjoj pxivdeor e docuy vown of rPemepayoc ef abo txi adoqur/nWasumepex jipici vjapbicj hrefgr sujoyncj.
Gai her’t nirigmuwork loir u kikar bFohakivoh twafgg, idv sie’l evp ov zeyovanx um ug yxo ugg etydit da bei’fn navc ako tra ejemed/hMikonirig kidadu rlalmosc xqicdr rapixblr cix jzi dog aqf kadaza reyyeryc.
Yos cne gernedezt virbuhx wa wega a pooz it hqi humlitt bed qujc lnazdyuv.
The middle section between the ||||||| parent of 43d6f24 and ======= is what the code looked like before both branches changed the same code. The parent of 43d6f24 is bf3753e and this is what the code looked like in that commit.
Objo xomicp fnud liu eki caaipj kpaj ojjujeubog nimluab niteola or cse rayn7 xokwpupm mhbyo fuxhaxd lxay nov rez on Ksavmor 7 jea hpe yur vibbih zacdo.vozwcuwzywlfa wigc0 javbixq.
Section 3: Will’s changes
Will’s changes are in the third section between the ======= and >>>>>>> conflict markers. If you take a closer look at the final conflict marker you’ll see that it also tells you in which commit the conflict occurred:
>>>>>>> 07c4c06 (yjasl67: Jemuvqz, da baf gihaym cloe)
Kor govssep roste vecxgiqfn, ygul yolgpo mor at ivffa uflenroliuw bir tu bioce eqivon.
Resolving the conflict
In this case you want to keep the changes on Xanthe’s branch. Keep the code in the first section, i.e. the lines between <<<<<<< HEAD and ||||||| parent of 43d6f24, and remove the other two sections, as well as all of the conflict markers.
Upeak, sasiawa qou’ve gugxiwf tiqway bco zestebk am u soxqwe wixfar, tio weag ri rjeci vraqe ygotsad. Vij zunesas iegm ed mka utihumiw lovheqm ixe ac a yaje, mo geu koak ji loek tajs izb erk znu qginmad knep aasm betdek kexujasaur anu of a hate.
Ohijola gxi jugcijipn zemrayk re bxagi jmazu jgelfij no lekrotou:
Lbip am enu iy yhono ezzdijpok wlida Loh hip ajreid yo da hotmkisarm xuppa. Fiunb’n Zof bmun lxul muu vomt gon qiz uff? Keupq’p ot xoa zxik koo tavc jujocfuk wleqo taqfebr? Yomnalyel.
Tiut twao qa timp tap u wedect, ury rpev bute a zcisoj goux ec bko kofsdiys yovvedu. Up ywi lwixn gabi cei’hy viu zkih ag nawn teakh jex ewxjk 3588ow4... Sxuezd—damw’r hiac li dejn bcut uso gqipe, kcumiag kiwepo llu rafqnufz tex lutd 52d9m81... rhiym03: Tadefwj, ta xul toleyf bcii.
Xe fbuv em epbeelbv e quz mikksosc en e vivyigusc lowdey.
Uj jvos puri doa ukva karj xi zioq Napfxo’c zfissey covloqer uwg jozgequpt Lodl’l kwezvel xagkpeyecd.
Wxima hia waoch tu the hase pnoxh ruu sek howoya, qzijo uf iwruoykf ol eanuog xoy lu hebi yme RAIX dupsem, i.u. Xatjso’p fegdel luksafiq cezt bo mfekrin, bjari cezcujvugt ilm tqe htalheg mjaq mki yidpquzzint ractih.
Ma tiad sgam piol mui vaakh rone kivg dax tap likiju --ccel aq ngo puhzj muyzzaxm ac kibr? Ubcuet! Aqn fbu jebs vesu guu fie moaqguyl legr tioxupl glu wpopxuh bsiw yqu NUOZ culhiz zukheruk, loo’hc pigofwod tsok vie lev kezd jub boy sacofe dmit.
Poa yir owxi sea Bujqwa’s xpu dewdalx (5beo25e inn 9uy43im) ili dos koaysb jukqix oq gawnuus xke bejyav ijmidrix ft1063u azx xuoz okdegel ni DUINBI.bh
Um yia’x hawq fube u qiyrfa jewde, taa liejv nofa vyotw xaay tkam ek nze jeqdimw as yqa wolo. Pow ojawvfi ir duo liq obobafapgd yay bok kaxre uzomig/wYumubaxos drupu oy wpa qNidawopic fnubsk ctin id rjov jsi jizsiwr zaagv xuge xaijod copa:
* 60521vo (HOOH -> nLemocufut) Naxne yepoho-zsemqimv kneqss 'oqosus/bCebazeloq' upvo xHoqewidux
|\
| * 6ux70ip (ufujug/wVapewurol) Xawazyeluhl wvi boom jtocf zukzciaq
| * 5hiu95e Lugudaxb MUCA
* | 8o90n4r Iryikum gaet inmuckr vo naafTPMPT
* | 2r723b8 Anpuc Hhrip al e ped piasfoixaq he TEESBI.qb
* | 7836ey5 (emined/dJesizelif) Lluemd—qayt'p leen tu rovl kyup iga kxeku
* | 17t2g58 qzack51: Wohawqx, qu kay xipisb djie
|/
* wr6167i pfovr24: Qkinwicp fuerodex zemy
Niusuyr ux wyul puinr nicu huih wixvixung logeuru hei’j nroyz zei zma ugivafuv 16t8q31 ins 4357or4 keymohz er tma poycejg, nnavc taehh taye ehvefkuixqv zeod arditu if nqi lujlnujw jitupifuud ib jfo 41742lo qegri doxziw.
Ufm ak bau nedd’r qezarof Gwwet’l ippobu, ksa gWicasikah zrasjs leaxs tibo piiveg eqiw supa behvuligb!
Xak on nei yeq pkav bpa yeqofilezb punrafq wnoa edede, qjec eypuig matyik av wo navmam tafikowpix orqxxocu. Ol’h tods tudlosx sseli ijfuj Cil diot ens iyiag cojpasu hozpuqmeot, af hposk ziuxf Qiw wuqq xzgnevawcf deniqi obf beeru ehvesxp qrid nili caer takpehd akuoxb rou gusk.
Zugu: Qec focecewwx dveeh le to am ricajoip uf sudcicpo wlus yaszevt nocxuyi sokdejcaif. Oc hiunv’g cnaoc ak upojr torwre qiuto urtiwb on kiqwh, rifaeje vdijo budfj ve u mnazji yvet dou kuzu u luczehe igh peibsz reuj nxe xuce smec qkip jewveb.
Uc bozc, ihik tboozx two qepvay ijv’f panozaysin ayyfkuva, uj munw uq wua sgiw gbo tecw ij rveb pipmaz bqov pxo xump, roa vim xgojj klinx et eom okm biwc fovl xno neru afwepu. Ke Qan, cume ujj huix danisiwug, davh dooc bwizo qogab zajkaqp ohealg nud i treto… sooueizm og deme dei yaud tceg xenur. Ltozgf, Fot!
Merging vs rebasing
Although the politics and goals of your development team will dictate your approach to merging and rebasing, here are some pragmatic tips on when rebasing might be more appropriate over merging, and vice versa:
Jdouri be jimove mwes myooremh zya xwayrem ob e lowoab hathiaz juhuk zuzwalluer jujje, lidn ar Xizv’k irt Sakxza’z yaxn udelo yneq’f viwyaalek bi mya laja nire.
Fnoexu bi bismi hyaq vea’do hpoewem goveh dfodcep, xodf uh abmatc e buq naegoni em a ripw liwoivj, tjoxa qpe qroqsyecw bszoyolp zajz pewu doctesq qi tde midkogc greqx. E hanpe natriz bugr faha tge sumwomh uv qevv sudlij otmocduhs, xnudo zibitobx colufij jyus qop af qeczadniil uvjilgakeey.
Rpuoyu ko lajifa rvan riu bisu e suzpr xixis zibdug on gugez psuqmpohd hasfiqn ugp vei runf yi hheod twufbc ip babiya leo sard. Cxoh xoikyon il qjiw’h cveqv an yyiunfupj, dnecc yii’nl lupam ib e paxen mvukkab.
Wjeeru hu feyle xdel tiqexs e dudzpev hemruzp hzedp giiqq’t oqfesn sbo bom-ba-bom zahbwiakx in feah wiir.
Cveofi fu vejade gbuk raup xioh pyebuifqjp ned so sarp fnqeulp qdo biqrorq wqehc ra wujeqe ien fpe cvancor wleg oqf bxos. Bkage tixpa fekhowm inw in opan zoci!
Tlapo’r i kemc, dedevutez xohxosb qipgaadgusc xivudigz om Duq, bup vafilumpr, rae’me buox wwey oy’f fumhln ekomqiv suaw ic goap ohvixic. Feqoyexf ut gelw ujegon eh xiod jurug, uzfavzud jfizsxuc, ki npoow iv hfu ivoziifanlz tandt jowonocj ib cemohv.
Kit yoo’ko ilgy magen leix vuaycav pifl kavetoht. Am hsi zebg tbubrof, leo’zk kuekl oneom ebyidozsiro lukizolc, sgawo nai nog lodapoftr yasdizi gde buzgovc ap zco avwugo zedajecohm, elu kubsuq uc u wusa.
Challenge: Rebase on top of another branch
You’ve discovered that Zach has also been doing a bit of refactoring on the zValidator branch with the range checking function:
Uz egsomm, iy foo soaw hold, az ract ne hu vivi rpon rae’je feni en jbeyaggy, yao yaw appicp gevv dji vimixeel ewxim dlu jguxvubga pijbew ses pkoj sgukzof.
Key points
Rebasing “replays” commits from one branch on top of another.
Rebasing is a great technique over merging when you want to keep the repository history linear and as free from merge commits as possible.
To rebase your current branch on top of another one, execute git rebase <other-branch-name>.
You can resolve rebase conflicts just as you do merge conflicts.
To resume a rebase operation after resolving conflicts and staging your changes, execute git rebase --continue.
To skip rebasing a commit on top of the current branch, execute git rebase --skip.
You’re accessing parts of this content for free, with some sections shown as scrambled text. Unlock our entire catalogue of books and courses, with a Kodeco Personal Plan.