Git

From 탱이의 잡동사니
Revision as of 12:53, 15 July 2015 by Pchero (talk | contribs) (Created page with "== Overview == Git 사용법 정리. == clone == === branch clone === 특정 branch clone 하기<ref>http://stackoverflow.com/questions/1911109/clone-a-specific-git-branch</...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Overview

Git 사용법 정리.

clone

branch clone

특정 branch clone 하기<ref>http://stackoverflow.com/questions/1911109/clone-a-specific-git-branch</ref>.

$ git clone -b <branch> <remote_repo>

Example
$ git clone -b my-branch git@github.com:user/myproject.git

Alternative (no public key setup needed):
$ git clone -b my-branch https://git@github.com/username/myproject.git

With Git 1.7.10 and later, add --single-branch to prevent fetching of all branches. Example, with OpenCV 2.4 branch:
$ git clone -b 2.4 --single-branch https://github.com/Itseez/opencv.git opencv-2.4

References

<references />