git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Clemens Buchacher <drizzd@aon.at>
To: Junio C Hamano <gitster@pobox.com>
Cc: Johannes Sixt <j6t@kdbg.org>, git@vger.kernel.org
Subject: Re: [PATCH] do not overwrite untracked symlinks
Date: Mon, 21 Feb 2011 20:46:23 +0100	[thread overview]
Message-ID: <20110221194623.GA31181@localhost> (raw)
In-Reply-To: <7vaahpluy9.fsf@alter.siamese.dyndns.org>

Hi Junio,

On Sun, Feb 20, 2011 at 11:15:26PM -0800, Junio C Hamano wrote:
> 
> The title of the test says that checkout must keep a/b-2/c/d; if "git
> checkout" without "-f" doesn't do so and you had to change it to "git
> checkout -f", it would mean one of two things: (1) you broke "checkout",
> or (2) the behaviour the test wanted to keep working turned out to be
> unwanted (iow, "git checkout" without "-f" should fail under the initial
> condition this test sets up).

I didn't write the test, but to me it looks like the test wants to
make sure that while the symlink is removed, the tree it's pointing
to is not removed. I am not sure why that was ever a concern. But
by adding -f the test stays the same, except for the fact that it
is now forcefully overwriting a symlink, which could be done
silently before.

But I am fine with removing the test if you think it's meaningless.
And Hannes posted a number of tests for "symlink preservation"
earlier in this thread:

 http://mid.gmane.org/201102051918.44848.j6t@kdbg.org

We should rename the test to 2020, since 2019 is by now already
taken.  But otherwise I think the tests are fine as-is. I also used
them to test my patch.

Clemens

  reply	other threads:[~2011-02-21 19:44 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-02 19:25 untracked symlinks are less precious than untracked files? Johannes Sixt
2011-02-02 20:03 ` Junio C Hamano
2011-02-02 22:24   ` Johannes Sixt
2011-02-05 18:18     ` [PATCH] Demonstrate breakage: checkout overwrites untracked symlink with directory Johannes Sixt
2011-02-05 18:33       ` Clemens Buchacher
2011-02-09 23:48         ` Junio C Hamano
2011-02-10 21:49           ` Clemens Buchacher
2011-02-20 12:13         ` [PATCH] do not overwrite untracked symlinks Clemens Buchacher
2011-02-21  7:15           ` Junio C Hamano
2011-02-21 19:46             ` Clemens Buchacher [this message]
2011-02-22  6:54               ` Junio C Hamano
2011-02-22 19:26                 ` Clemens Buchacher
2011-02-22 20:01                   ` Junio C Hamano
2011-02-15  7:24       ` [PATCH] Demonstrate breakage: checkout overwrites untracked symlink with directory Johannes Sixt

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

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20110221194623.GA31181@localhost \
    --to=drizzd@aon.at \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=j6t@kdbg.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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).