Frage

For some reason when I set up my git repository git clone lists all the files in that particular drive, i.e.

% git status  # On branch master 
# Changes not staged for commit:
#   (use "git add/rm <file>..." to update what will be committed)
#   (use "git checkout -- <file>..." to discard changes in working directory)
#
#   deleted:    index.html
#
# Untracked files:
#   (use "git add <file>..." to include in what will be committed)
#
#   ../../../-framework dla ASHA
#   ../../../.CFUserTextEncoding
#   ../../../.Trash/
#   ../../../.Xauthority

The output is much longer which makes project management a bit of a pain.

I have no idea why this happened, I have used git before but never had this problem which makes me think I missed something obvious.

War es hilfreich?

Lösung

Use the following command to find out what Git thinks the root directory of your project is:

git rev-parse --show-toplevel

Given that, you might be able to discover something about why Git is doing what you observe.

Also check to make sure that you don't have an unexpected value set for the GIT_DIR environment variable.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top