Reputation: 3654
I have the following scenario:
git checkout feature_branch
feature_branch
master
was updated with things that I want to have in feature_branch
as wellfeature_branch
to origin
git checkout master && git pull && git merge fr_1285
Now master is up to date and has all my changes in it (I'm not sure this is exactly what I wanted, though).
From this point, how can I continue working on my own (already pushed) feature_branch
using the updated files in master
? Have I already screwed up?
Upvotes: 0
Views: 64
Reputation: 11541
First commit the changes to the feature branch, then do git checkout origin master
prior to do a git pull
to the master (you will have all the codebase in the origin master up to date). Then you can merge the feature branch to the master branch by:
git merge feature_branch
You need to finalize with a git push origin master
to have all the changes from future branch included in the master branch.
You can continue your work on the feature branch by checking out.
git checkout feature_branch
Upvotes: 1
Reputation: 57
You could get all your changes from master to feature _branch by rebasing feature_branch onto master
Upvotes: 0