Let's say (hypothetically) that I wanted to make a symlink to my Documents folder on my Desktop. I would do this:
cd ~/Desktop
ln -s ~/Documents
which will make a symlink called Documents on my Desktop.
However, when I do this (note the trailing slash after ~/Documents
:
cd ~/Desktop
ln -s ~/Documents/
I get:
ln: ./: File exists
Howcome? Why does the trailing slash matter in this case, and what does a trailing slash mean in general?