All of lore.kernel.org
 help / color / mirror / Atom feed
From: Martin Waitz <tali@admingilde.org>
To: Linus Torvalds <torvalds@osdl.org>
Cc: git@vger.kernel.org
Subject: Re: git reset --hard not removing some files
Date: Fri, 2 Jun 2006 11:37:36 +0200	[thread overview]
Message-ID: <20060602093736.GL14325@admingilde.org> (raw)
In-Reply-To: <Pine.LNX.4.64.0606010918060.5498@g5.osdl.org>

[-- Attachment #1: Type: text/plain, Size: 1294 bytes --]

hoi :)

On Thu, Jun 01, 2006 at 09:21:38AM -0700, Linus Torvalds wrote:
> Those files were _never_ tracked.

You are right, I used the wrong demonstration to show my problem.
I had one problem like this in the linux-kernel and tried to
reproduce them in the git repository but did it wrong...

GIT reset seems to have a problem when a file is tracked and ignored
at the same time.

This fails:

diff --git a/t/t7101-reset.sh b/t/t7101-reset.sh
index a919140..865e0f6 100755
--- a/t/t7101-reset.sh
+++ b/t/t7101-reset.sh
@@ -21,10 +21,12 @@ test_expect_success \
      cp ../../COPYING path1/COPYING &&
      cp ../../COPYING COPYING &&
      cp ../../COPYING path0/COPYING-TOO &&
+     echo COPYING > .gitignore &&
      git-add path1/path2/COPYING &&
      git-add path1/COPYING &&
      git-add COPYING &&
      git-add path0/COPYING-TOO &&
+     git-add .gitignore &&
      git-commit -m change -a'

 test_expect_success \


This hit me as the Linux kernel .gitignore includes ".*" which matches
all the .gitignore files and so they are not removed when you go
back to 2.6.13.  But with the new git checks regarding files in
the working dir, git then refuses to pull in newer Linux versions
because it would overwrite ".gitignore".

-- 
Martin Waitz

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

  reply	other threads:[~2006-06-02  9:37 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-06-01 16:00 git reset --hard not removing some files Martin Waitz
2006-06-01 16:13 ` Sean
2006-06-01 16:13   ` Sean
2006-06-01 17:21     ` Jakub Narebski
2006-06-01 19:21       ` Sean
2006-06-01 19:21         ` Sean
2006-06-02  8:16           ` Jakub Narebski
2006-06-01 16:21 ` Linus Torvalds
2006-06-02  9:37   ` Martin Waitz [this message]
2006-06-02 10:08     ` Sean
2006-06-02 10:08       ` Sean
2006-06-02 14:17       ` Martin Waitz
2006-06-02 14:57   ` Junio C Hamano
2006-06-03  8:48     ` Junio C Hamano
2006-06-03 15:11       ` Linus Torvalds
2006-06-04  9:16     ` Martin Waitz
2006-06-04  9:31       ` 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=20060602093736.GL14325@admingilde.org \
    --to=tali@admingilde.org \
    --cc=git@vger.kernel.org \
    --cc=torvalds@osdl.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.