This scheme has the advantage that if you update the source, you need not propagate the change to the other architectures by hand, since all source in all shadow directories are symlinks to the real thing: just cd to the shadow directory and recompile away.
The todir argument is optional and defaults to the current directory. The fromdir argument may be relative (e.g., ../src) and is relative to todir (not the current directory).
If you add files, simply run lndir again. New files will be silently added. Old files will be checked that they have the correct link.
Deleting files is a more painful problem; the symlinks will just point into never-never land.
Normally lndir outputs the name of each subdirectory as it descends into it. The -silent option suppresses these status messages. -silent may be abbreviated to -s.
If a file in fromdir is a symbolic link, lndir will make the same link in todir rather than making a link back to the (symbolic link) entry in fromdir. The -ignorelinks option changes this behavior. The link created in todir will point back to the corresponding (symbolic link) file in fromdir. If the link is to a directory, this is almost certainly the wrong thing. The -ignorelinks option may be abbreviated to -i.
If a file in fromdir is a symbolic link to a directory and the -withsymdirs option is specified, lndir will shadow the directory tree the symbolic link points to, whether or not the -ignorelinks is also specified. The -withsymdirs option may be abbreviated to -d.
lndir will remove dangling symbolic links and empty directories in the shadow tree. The -clean option may be abbreviated to -c.
lndir will do the cleaning phase only, not creating the shadow tree. The todir argument may be provided, and defaults to the current directory when not provided.
lndir will normally not shadow any BitKeeper, RCS, SCCS, CVS, CVS.adm and .svn subdirectories, nor any .cvsignore and .gitignore files. This option causes these directories and files to be treated as any other, rather than ignored. -withrevinfo may be shortened to -r.
By default, lndir does not shadow files or directories whose name is .DS_Store, or ._.DS_Store, or starts with '.#', or ends in '~'. This option, which may be abbreviated to -E, causes such files to also be shadowed.
This option adds name to an initially empty list of filenames in fromdir that are not to be shadowed. -except may be specified as -e. This option may be repeated as many times as necessary.
A warning message is displayed if the symbolic link cannot be created. The usual problem is that a regular file of the same name already exists.
If the link already exists but doesn't point to the correct file, the program prints the link name and the location to which it does point.
Table of Contents