Hacker News new | ask | show | jobs
by micah_chatt 2454 days ago
This. It extends to command line tools too. I can _never_ remember what the order is for `ln -s`.
2 comments

I remember the order for ln -s because the third argument is optional. If you omit the third argument the command will create a symbolic link in the current directory with the same filename as the original.
I remember this usage the exact same way :)
Unix tools are pretty consistent that source comes before destination. If you get stuck, just remember that it's the same as cp, mv, etc.
I think the confusion comes because you have to do

    ln -s bar foo
so that "ls -l" then prints

    foo -> bar
People who look at an existing symlink before trying to create a new one will get confused.

Of course, the solution is to remember that ln is in the same family as cp and mv; ls is a different family.