Created
August 7, 2014 08:55
-
-
Save kyu999/2d38ed992e919ee1e8f8 to your computer and use it in GitHub Desktop.
gitで変な変更がpush時に混ざった原因
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git branchを切ったらそのbranchは現在のbranchから切られることになるので、必ずdevelopmentからbranchを作る。 | |
developmentがlocalにない場合は | |
``` | |
git checkout -b development origin/development | |
``` | |
これでローカルにdevelopmentを作る。引数の -b はbranchを切りつつcheckoutをするということ。 | |
addしてしまったものをいったん横においておきたいときは | |
``` | |
git stash save | |
``` | |
でわきにおいておくことができる。 | |
save一覧は | |
``` | |
git stash list | |
``` | |
で見る | |
もしその脇に置いた変更をもとに戻したいときは | |
``` | |
git stash pop | |
``` | |
で最新のstashを現在のbranch上に移動できる | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment