I recently added and committed a symbolic link to a text file (in an external directory) to a git repository. I expected this would commit the innards to the text file. However, when I cloned the repository to a second machine, the symbolic link was indeed still a symbolic link. It was now pointing at an unrelated text file (of the same name) on the second machine. My question is, why and how did git behave in this way?
Why is it possible to commit the actual link itself and when might this be useful?
Thank you!