All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jakub Narebski <jnareb@gmail.com>
To: git@vger.kernel.org
Subject: Re: [PATCH] Introduce git-mirror, a tool for exactly mirroring another repository.
Date: Wed, 01 Nov 2006 13:23:33 +0100	[thread overview]
Message-ID: <eia3jk$n2f$1@sea.gmane.org> (raw)
In-Reply-To: 20061101151859.0e984d3f.vsu@altlinux.ru

Sergey Vlasov wrote:

>> Perhaps just don't remove log when branch is deleted. I tend for example
>> to be careful when reordering commits on a branch, and use git branch -f
>> instead of deleting and recreating branch to not lose reflog.
> 
> Keeping the reflog does not help - reflog entries are not refs, and do
> not keep the referenced objects live in the repository.  Therefore old
> objects will be lost when the repository is repacked and pruned.

Well, now to reorder and choose which commits on branch to save, and
optionally also rebase, I use
$ git branch tmp
$ git branch -f <branch> <upstream>
$ git checkout <branch>
$ git cherry-pick tmp~<n>
...
$ git branch -D tmp

> Also, the reflog really must be deleted together with the ref itself -
> otherwise it may cause a file/directory conflict when another ref is
> created.  Of course, if the ref is renamed instead of deleting, the
> corresponding reflog may be renamed too.

There is currently no command to rename branch (and rename reflog).
It would be nice if git-branch could also rename branch (and reflog).
-- 
Jakub Narebski
Warsaw, Poland
ShadeHawk on #git


  reply	other threads:[~2006-11-01 12:24 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-25  4:46 [PATCH] Introduce git-mirror, a tool for exactly mirroring another repository Shawn Pearce
2006-09-26  4:45 ` Junio C Hamano
2006-09-26 21:57   ` Shawn Pearce
2006-10-31 14:42 ` Sergey Vlasov
2006-10-31 14:55   ` Shawn Pearce
2006-11-01  0:32   ` Junio C Hamano
2006-11-01  1:08     ` Jakub Narebski
2006-11-01 12:18       ` Sergey Vlasov
2006-11-01 12:23         ` Jakub Narebski [this message]
2006-11-01 16:15         ` Junio C Hamano

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='eia3jk$n2f$1@sea.gmane.org' \
    --to=jnareb@gmail.com \
    --cc=git@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.