Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

git still untracked after add

Everytime I do git status there is this folder that appears as untracked.

$ git status
# On branch master
# Untracked files:
#   (use "git add <file>..." to include in what will be committed)
#
#       src/error/
nothing added to commit but untracked files present (use "git add" to track)

Even after doing git add ., git commit -a the folder at src/error keeps showing up as untracked. Other unstaged files get commited everytime only this folder keeps giving problems. Also git doesnt report any errors. What could be the problem here ?

like image 494
slayerIQ Avatar asked Aug 10 '10 07:08

slayerIQ


People also ask

How do I fix nothing added to commit but untracked files?

To fix this error, either add the files causing the error to the staging area or ignore them using the . gitignore file.

Why is my file untracked git?

Untracked files are the ones still not versioned—”tracked”—by Git. This is the state of new files you add to your repository. That basically means Git is aware the file exists, but still hasn't saved it in its internal database.


1 Answers

I found the problem and the solution this is what happened:

First src/error was called src/Error when i changed the case locally the foldername was changed but in git it was still commited as src/Error. Windows is case-insensitive so what i did was remove the folder commit and add it again with the right casing.

like image 188
slayerIQ Avatar answered Sep 18 '22 23:09

slayerIQ