I want to create a branch from an existing remote branch (let\'s say remote-A) and then commit the changes to the repository.
I have used the below commands to create a
Old post, still I'd like to add what I do.
1. git remote add
2. git fetch
3. git checkout -b /
This series of commands will
Now if you want to publish this new local branch to your remote and set the upstream url also
git push origin +
Also, if only taking in remote changes was your requirement and remote already exists in your local, you could have done, instead of step 2 and 3,
git pull --rebase
and then opted for
git mergetool
(needs configurations separately) in case of any conflicts, and follow console instructions from git.