Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Now, why isn't that in the ln man pages?


It is.

  SYNOPSIS
       ln [OPTION]... [-T] TARGET LINK_NAME   (1st form)
He just replaced TARGET with 'orig'


The confusion comes from understanding what the target of a link is. Of course, it's not the new file you're creating, it's the source. But if you were copying the file, then the target would be the destination.

Hence the confusion, I guess.

(I don't think I've ever read the ln man page. I learned it by trying it both ways until I learned which way was correct.)


OpenBSD always has great documentation: http://www.openbsd.org/cgi-bin/man.cgi?query=ln

  SYNOPSIS
     ln [-fhns] source [target]
     ln [-fs] source ... [directory]
Not to mention the detailed description as well as informative examples.


I admit it's confusing, but I don't think it can be put much more succinctly than the man page makes it. The part where the name of the link itself is called "link name" really drives the point home.

I definitely refer to ln more than any other man page... Every time I use ln I say "target, link name" in my head.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: