git@vger.kernel.org list mirror (unofficial, one of many)
 help / color / mirror / code / Atom feed
From: "Torsten Bögershausen" <tboegi@web.de>
To: Angelo Melonas <angelomelonas@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: Possible minor bug in Git
Date: Thu, 31 Jan 2019 20:34:47 +0000	[thread overview]
Message-ID: <20190131203447.aovalz2vzsjpdjdv@tb-raspi4> (raw)
In-Reply-To: <CAHYHVP+Dvbq_aOMy1_Kq0LHJsd4r+4GiP3N3R4A9ouAoJ4gw9g@mail.gmail.com>

On Thu, Jan 31, 2019 at 09:29:28AM +0200, Angelo Melonas wrote:
> Just to clarify, I made a mistake above. Instead of "untracked", I
> meant "unstaged".
> I apologise for the confusion.
>
> On Thu, Jan 31, 2019 at 9:01 AM Angelo Melonas <angelomelonas@gmail.com> wrote:
> >
> > Good day,
> >
> > I found a potential bug in Git for Windows. The bug can be reproduced
> > as follows:
> >
> > 1. Modify a file so that it shows up as "untracked" when executing the
> > "git status" command.
> > 2. Attempt to "git add" the file, but change the case of a single
> > letter. The command executes but no warning or error is displayed.
> > 3. Execute "git status" again and it still shows the file as "untracked".
> >
> > Please let me know if I am mistaken. I also have a screenshot
> > demonstrating the "bug" which I cannot attach to this email, but which
> > can be requested.
> >
> > Have a great day.
> >
> > Kind regards,
> > Angelo Melonas

See the example below, Git tracks AA.txt, so you must run
git add AA.txt

After a commit, you can tell Git that the file was renamed:
git mv AA.txt Aa.txt
(and then a commit)



------------------------------

user@mac:/tmp/tt2> git init
Initialized empty Git repository in /private/tmp/tt2/.git/
user@mac:/tmp/tt2> echo AAA > AA.txt
user@mac:/tmp/tt2> git add AA.txt
user@mac:/tmp/tt2> git commit -m AA.txt
[master (root-commit) f102760] AA.txt
 1 file changed, 1 insertion(+)
  create mode 100644 AA.txt
  user@mac:/tmp/tt2> echo BB >AA.txt
  user@mac:/tmp/tt2> mv AA.txt  Aa.txt
  user@mac:/tmp/tt2> git status
  On branch master
  Changes not staged for commit:
    (use "git add <file>..." to update what will be committed)
      (use "git checkout -- <file>..." to discard changes in working directory)

        modified:   AA.txt

no changes added to commit (use "git add" and/or "git commit -a")
user@mac:/tmp/tt2> git add AA.txt
user@mac:/tmp/tt2> git status
On branch master
Changes to be committed:
  (use "git reset HEAD <file>..." to unstage)

        modified:   AA.txt

user@mac:/tmp/tt2>

  reply	other threads:[~2019-01-31 20:34 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-31  7:01 Angelo Melonas
2019-01-31  7:29 ` Angelo Melonas
2019-01-31 20:34   ` Torsten Bögershausen [this message]
2019-02-01  8:02     ` Angelo Melonas
2019-02-02  6:38       ` Torsten Bögershausen
2019-02-06 22:17         ` Giuseppe Crinò
2019-02-07 19:41           ` Johannes Schindelin
2019-02-08 17:43             ` Torsten Bögershausen
2019-02-09 18:19             ` Philip Oakley
2019-02-10 22:46               ` Giuseppe Crino'

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=20190131203447.aovalz2vzsjpdjdv@tb-raspi4 \
    --to=tboegi@web.de \
    --cc=angelomelonas@gmail.com \
    --cc=git@vger.kernel.org \
    --subject='Re: Possible minor bug in Git' \
    /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

Code repositories for project(s) associated with this 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).