How to switch to master from phpstorm software
PHP中文网
PHP中文网 2017-05-24 11:31:17
0
2
790

Help, all the great gods. . I used git for the first time when I joined a new company. I cloned the master of the remote warehouse to the local one. Then my superior said that there was something in the branch. I didn’t know how to enter the branch, so I created a branch in the lower right corner (I clicked wrongly). Now that I have been on this branch, how can I switch back to master?

PHP中文网
PHP中文网

认证高级PHP讲师

reply all(2)
洪涛

Don’t look at the red color in the second picture, I already have this branch locally

PHPzhong

There is a Terminal tool on the toolbar at the bottom of phpstorm. Click it and enter the following command:

git branch #View current branch

When the current branch is clean, switch to master

git checkout master

Switch to dev

git checkout dev

Note: You must ensure that this branch is clean before switching. You can use git status to check it

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template