here is a situation:
I was on branch1
and pushed my changes. Then I did second task on branch2
and pushed it too. After, I switched again to a branch1
and added some code into it, pushed again. Now I'm in branch2
again and do not have last changes which was made in branch1
.
How can I do it?
I frequently use this to pull from master into a working branch. git pull origin branch1
Try mergin branches.
git pull --all
git checkout branch2
git merge branch1
You might need to resolve some merge conflicts
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.