2016-01-18 35 views
1

我正在看一個燒瓶應用程序,我想導入到openshift項目(https://github.com/lpolepeddi/intro-to-flask)。這包含一系列'檢查點'(分支)作爲嘖嘖的一部分。我想抓住最終的代碼https://github.com/lpolepeddi/intro-to-flask/tree/20_visibility_control作爲項目的起點。是一種方式來獲得對錶單的這個分支獨特的git的URLgithub回購與多個分支獨特的git網址?

https://github.com/lpolepeddi/intro-to-flask.git 

所以,我可以用以下命令將其在:

git remote add upstream -m master https://github.com/shekhargulati/flask-login-openshift-quickstart.git 
+0

Git沒有「檢查點」的概念。也許你的意思是分支? – Chris

+0

對不起,他們把它稱爲檢查點在文章和回購https://github.com/lpolepeddi/intro-to-flask/tree/20_visibility_control但你是對的,他們是分支機構 – user61629

+0

http://stackoverflow.com/questions/3471827/how-do-i-list-all-remote-branches-in-git-1-7 –

回答

3

雖然據我所知「單分支GitHub的網址」不存在,你可以只克隆整個回購和後來改變分支:

git clone https://github.com/lpolepeddi/intro-to-flask.git 
cd intro-to-flask 
git checkout 20_visibility_control 

或作爲this answer指出,克隆只有一個分支:

git clone --branch 20_visibility_control --single-branch https://github.com/lpolepeddi/intro-to-flask.git 
相關問題