git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Drew Northup <drew.northup@maine.edu>
Cc: git@vger.kernel.org
Subject: Re: rm and add, but not rename, of identical files
Date: Wed, 10 Oct 2012 14:47:26 -0700	[thread overview]
Message-ID: <7v1uh6atjl.fsf@alter.siamese.dyndns.org> (raw)
In-Reply-To: <1349894347.32696.10.camel@drew-northup.unet.maine.edu> (Drew Northup's message of "Wed, 10 Oct 2012 14:39:07 -0400")

Drew Northup <drew.northup@maine.edu> writes:

> # Untracked files:
> #   (use "git add <file>..." to include in what will be committed)
> #
> #       rc.d/rc2.d/S08iptables
> #       rc.d/rc3.d/S08iptables
> #       rc.d/rc4.d/S08iptables
> ...
> no changes added to commit (use "git add" and/or "git commit -a")
>
> It detects the changes as renames however―which in this case isn't
> appropriate:
>
> [root@drew-northup ~]# etckeeper vcs status
> # On branch master
> # Changes to be committed:
> #   (use "git reset HEAD <file>..." to unstage)
> #
> #       renamed:    rc.d/rc2.d/K92iptables -> rc.d/rc2.d/S08iptables
> #       renamed:    rc.d/rc3.d/K92iptables -> rc.d/rc3.d/S08iptables
> #       renamed:    rc.d/rc4.d/K92iptables -> rc.d/rc4.d/S08iptables
> #...

Given that all of these six files have the same contents, I actually
am slightly impressed how well Git matched them up ;-).

But more seriously, why do you have rc.d/rc2.d/S08iptables untracked
in the working tree but in the index to be committed?

  parent reply	other threads:[~2012-10-10 21:47 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-10 18:39 rm and add, but not rename, of identical files Drew Northup
2012-10-10 20:09 ` Andreas Schwab
2012-10-10 21:47 ` Junio C Hamano [this message]
2012-10-11 15:10   ` Drew Northup
2012-10-11 16:53     ` 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=7v1uh6atjl.fsf@alter.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=drew.northup@maine.edu \
    --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 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).