I've seen a few git-with-symlinks questions answered on here, but I'm still puzzled by this one.
Suppose I've added directories to a git repository, then later replaced the directory with a symbolic link having the same name. The files are "still there" in the sense that they still have the same path through the symbolic link. However, since git doesn't follow the links, the files are ostensibly forgotten/deleted. However, no mention of this is made when I run "git status."
I was happily working away thinking nothing was wrong until I realized the files were considered deleted by running "git diff."
Thus, I have two questions: is there a reason the files wouldn't show up in "git status" as deleted or moved? Also, how can I get the files re-added?
For those who aren't sure what I'm talking about, consider this example:
$ git init
$ mkdir path
$ touch path/file
$ git add path
$ git commit -a -m "added file"
Then...
$ git status
# On branch master
nothing to commit (working directory clean)
Then...
$ mv path path2
$ ln -s path2 path
$ git status
# On branch master
# Untracked files:
# (use "git add ..." to include in what will be committed)
#
# path
# path2/
nothing added to commit but untracked files present (use "git add" to track)
Yet...
$ git diff
diff --git a/path/file b/path/file
deleted file mode 100644
index e69de29..0000000
Thanks! Tom