I need to create an orphan branch, which has no parent. How do I do it in Smartgit?

Need some guidance on this..

有帮助吗?

解决方案

That is one instance where, if SmartGit doesn't support the orphan option from the GUI, you could as well use the CLI (command-line interface) and type a quick:

git checkout --orphan newbranch

(as in "In git, is there a simple way of introducing an unrelated branch to a repository?")

Commit at least one file (still through the GUI):

git add afile
git commit -m "a first commit in orphan branch"
# no push here, this is purely a local operation in your local repo

Then you go back in SmartGit and your new (orphan) branch should be there.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top