How do I track, pull, etc. from an existing git branch on Github -


i have master branch repository on github cloned on machine. there other existing branches in repository able switch , use. i'm trying use command:

git branch --track nameofbranch origin/nameofbranch 

this isn't working me. error:

error: requested upstream branch (url) not exist 

basically need create branch on local machine , tie existing branch. thank help!

i think understand want. create local tracking branch can work on following should work.

first need clone repository:

$ git clone git://thisismyrepo.com/project $ cd project 

next find branch want working on:

$ git branch -a 

that output branches in repo. next want switch on branch want work on by:

$ git checkout origin/examplebranch 

in order work on branch can do:

$ git checkout -b examplebranch origin/examplebranch 

that should cause track , allow work on local branch. hope helps.


Comments

Popular posts from this blog

java - JavaFX 2 slider labelFormatter not being used -

Detect support for Shoutcast ICY MP3 without navigator.userAgent in Firefox? -

web - SVG not rendering properly in Firefox -