From: "Sverre Rabbelier" <alturin@gmail.com>
To: "Jakub Narebski" <jnareb@gmail.com>
Cc: "Ulrik Sverdrup" <ulrik.sverdrup@gmail.com>,
git@vger.kernel.org, "Wincent Colaiuta" <win@wincent.com>,
"Junio C Hamano" <gitster@pobox.com>,
"Pedro Melo" <melo@simplicidade.org>
Subject: Re: Parent-less branches
Date: Sat, 3 May 2008 02:46:01 +0200 [thread overview]
Message-ID: <bd6139dc0805021746q40b384c3nb36a8605d9475a7f@mail.gmail.com> (raw)
In-Reply-To: <m38wys6y1q.fsf@localhost.localdomain>
On Sat, May 3, 2008 at 2:17 AM, Jakub Narebski <jnareb@gmail.com> wrote:
> In short the solution is to create content-less branch using:
>
> $ git symbolic-ref HEAD refs/heads/newbranch
> $ rm .git/index
>
> then commit.
I guess what Pedro is asking is if there isn't a builtin way to do
this. Which, if I understand correctly, there isn't. Perhaps though
something like "git branch -N newbranchname" which then creates a new
parentless branch. It could just be a shell script that does the
above, but I wonder if there are no side-effects of the above? It
sounds somewhat 'messy' to remove the index? Too 'low level' to do for
a user I mean, what if sometime in the future we decide to store
something in the index that -is- important? I reckon it would be
cleaner to add an option for this.
--
Cheers,
Sverre Rabbelier
next prev parent reply other threads:[~2008-05-03 0:46 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-02 23:20 Parent-less branches Ulrik Sverdrup
2008-05-03 0:17 ` Jakub Narebski
2008-05-03 0:46 ` Sverre Rabbelier [this message]
2008-05-04 5:50 ` Daniel Barkalow
-- strict thread matches above, loose matches on Subject: below --
2008-05-02 21:05 Pedro Melo
2008-05-02 21:47 ` Junio C Hamano
2008-05-02 22:32 ` Wincent Colaiuta
2008-05-02 23:04 ` Pedro Melo
2008-05-02 23:04 ` Pedro Melo
2008-05-02 23:34 ` Randal L. Schwartz
2008-05-03 14:05 ` Johannes Schindelin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=bd6139dc0805021746q40b384c3nb36a8605d9475a7f@mail.gmail.com \
--to=alturin@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=jnareb@gmail.com \
--cc=melo@simplicidade.org \
--cc=sverre@rabbelier.nl \
--cc=ulrik.sverdrup@gmail.com \
--cc=win@wincent.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).