LoginSignup
18
19

More than 5 years have passed since last update.

リモートのGitブランチをローカルブランチに落とす

Last updated at Posted at 2014-08-21

リモートのGitブランチをローカルブランチに落とす

リモートブランチにどんなブランチがあるかを確認する。
gitの-aオプションでリモートブランチも一覧取得できる。

$ git branch -a

ローカルブランチ名を指定してリモートブランチを引っ張ってくる。

$ git checkout -b local_branch origin/remote_branch

-bオプションでブランチを作りながらチェックアウトする。
originとは、リモートの意味

18
19
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
18
19