ln
makes links between files. $ ln -s $target $symbolic_link_file
$target
can be any name. It's not resolved until $symbolic_link_file
is accessed. $ mkdir x y $ echo hello > x/to $ ln -s x/to y/from $ cat y/from # Error: no such file or directory! $ rm y/from $ ln -s ../x/from y/from $ cat y/from # Prints 'hello' $ cd y $ cat from # Prints 'hello'
readlink -f
-r
creates the symbolic links relative to the link location. find $DIR -type f -executable -exec ln -s {} ~/bin \;