From: Peter Baumann <waste.manager@gmx.de>
To: Julian Phillips <julian@quantumfyre.co.uk>
Cc: git@vger.kernel.org
Subject: Re: [BUG] git-new-workdir doesn't understand packed refs
Date: Wed, 18 Apr 2007 07:52:15 +0200 [thread overview]
Message-ID: <20070418055215.GA32634@xp.machine.xx> (raw)
In-Reply-To: <Pine.LNX.4.64.0704172253140.14155@beast.quantumfyre.co.uk>
On Tue, Apr 17, 2007 at 10:55:17PM +0100, Julian Phillips wrote:
> On Tue, 17 Apr 2007, Peter Baumann wrote:
>
> > running git-gc or git-gc --prune isn't save because e.g. all the tags
> > are packed and .git/packed-refs isn't shared on the several workdirs.
>
> Do you mean that the link wasn't created? Or that the link was removed and
> replaced with a file when you ran gc from a workdir?
>
The problem is, when I created the new workdir, I don't have a file
.git/packed-refs, so a new workdir was created with a dangling symlink,
e.g. workdir/.git/packed-refs -> repo/.git/packed-refs (but the last one
doesn't exist). As it seems, git gc removes the dangling symlink and
replaces it with a file.
Steps to reproduce (written in this mail; after /usr/bin/script gave me an
output whith color coded text *GRR* in ASCII squences):
mkdir a && cd a && git init
echo 1 > file.txt
git add file.txt
git commit -m "file added"
git tag v0
cd ..
git-new-workdir a b
cd b && git-gc
Oh. Wait. Just forget that theorie about dangling symlink. git-gc replaces
the symlink in a new workdir with a file. Just confirmed that.
So it isn't save to run git-gc in a workdir.
-Peter
next prev parent reply other threads:[~2007-04-18 5:52 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-17 16:17 [BUG] git-new-workdir doesn't understand packed refs Peter Baumann
2007-04-17 21:55 ` Julian Phillips
2007-04-18 5:52 ` Peter Baumann [this message]
2007-04-18 7:26 ` Julian Phillips
2007-04-18 7:40 ` Junio C Hamano
2007-04-18 8:11 ` Peter Baumann
2007-04-18 11:55 ` Julian Phillips
2007-04-18 16:23 ` Junio C Hamano
2007-04-18 17:43 ` Peter Baumann
2007-04-18 18:17 ` Junio C Hamano
2007-04-18 18:31 ` Peter Baumann
2007-04-18 18:42 ` Junio C Hamano
2007-04-18 21:08 ` Peter Baumann
2007-04-18 21:31 ` Junio C Hamano
2007-04-19 5:35 ` [PATCH] Add test for symlinked .git/packed-refs Peter Baumann
2007-04-19 6:06 ` Junio C Hamano
2007-04-20 16:52 ` [PATCH] pack-refs: dereference .git/packed-refs if it is a symlink Peter Baumann
2007-04-21 20:05 ` Junio C Hamano
2007-04-18 18:43 ` [BUG] git-new-workdir doesn't understand packed refs Julian Phillips
2007-04-18 10:28 ` [PATCH] pack-refs: dereference .git/packed-refs if it is a symlink Peter Baumann
2007-04-18 16:09 ` Linus Torvalds
2007-04-18 17:47 ` Peter Baumann
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=20070418055215.GA32634@xp.machine.xx \
--to=waste.manager@gmx.de \
--cc=git@vger.kernel.org \
--cc=julian@quantumfyre.co.uk \
/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.