If you try to push you will get the following message. Any uncommitted work will be taken along to the new branch. Just use: git checkout -b feature/newbranch. That extra power together with the easier to remember command make git restore a better choice than git checkout. Like stated in this question: Git: Create a branch from unstagged/uncommited changes on master: stash is not necessary. SourceTree: On the top bar click on icon 'Stash', type its name and create. Though this is technically not the 'proper' way to discard changes (as other answers and comments have pointed out). If you want to discard these changes later just git stash drop (or git stash pop to restore them).
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |