Re: [PATCH v3] git checkout: create unparented branch by --orphan
- From
- Peter Baumann <waste.manager@gmx.de>
- Date
- Mar 21, 2010, 17:14 UTC
- Message-ID
- <20100321171431.GE2557@m62s10.vlinux.de>
- In-Reply-To
- <1269185678-3039-1-git-send-email-erick.mattos@gmail.com>
On Sun, Mar 21, 2010 at 12:34:38PM -0300, Erick Mattos wrote:
Show 9 quoted lines
> Similar to -b, --orphan creates a new branch, but it starts without any > commit. After running "git checkout --orphan newbranch", you are on a > new branch "newbranch", and the first commit you create from this state > will start a new history without any ancestry. > > "git checkout --orphan" keeps the index and the working tree files > intact in order to make it convenient for creating a new history whose > trees resemble the ones from the original branch. >
Sorry to skim in so late but --orphan sounds - at least to me as a non native speaker - a little strange. Yes, I know it means "without parents", but actually it would be the *last* thing I would search for after opening the manpage.
Wouldn't --empty-parent or --no-parent describe the situation better? It actually has the benefit that it would match on a search for /parent/, which I would have searched for if I want to create a new empty branch.
-- Peter