Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- for avoiding conflict branches in the future, you should make checkout to master first, make a new branch, then you ca check out to it.
- ```bash
- git checkout master
- git branch <new-branch> #name it as you wish
- git checkout <new-branch>
- ```
- Or you could possibly as a shortcut do this by one command
- ```bash
- git checkout master
- # `-b` option will make a new branch and it will switch to it.
- git checkout -b <new-branch> #name it as you wish
- ```
- Or even shorter, with online you could do it as:
- ```bash
- # `-b` option will make a new branch and it will switch to it.
- # new-branch it could be `week2` and source-branch could be `master` in your case because we need to checkout from the master branch.
- git checkout -b <new-branch> <source-branch>
- ```
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement