home *** CD-ROM | disk | FTP | other *** search
-
- makelink.TV 42.1
- ~~~~~~~~~~~~~~~~
-
- Overview:
-
- Well, in the development of AmiNIX I needed a quick program to be capable
- of making soft links (symbolic links under AmiNIX). Since with 3.1 C=
- still hadn't made makelink soft-link capable, I wrote makelink.TV to
- replace it. This functions identically to C='s makelink, except (for now)
- the hard link loop detection isn't implemented. But it's 48 bytes smaller
- than C='s makelink V37, and also supports soft links. This version is also
- pure and can be made resident just like C='s makelink.
-
- I hope to add the loop detection to make it 100% C= makelink compatible,
- but until then you should be smart enough not to link a directory to
- a directory link underneath itself. :)
-
- A note about using soft links: Many programs may fail when using soft
- links as implemented in the V37+ dos.library. Soft links are only
- directly resolved if they are last in the path (i.e. if `link' is a link,
- and you access `link/file', it won't work). But if the program traverses
- the soft link and then locks the file underneath it, it will work. Note
- that soft links to files are therefore fine, but soft links to directories
- may or may not work. It is known that the Workbench and DirWork 2.1 both
- correctly handle soft links to directories. There are PD patches to
- dos.library to fix this bug, but I'm not aware of their names.
-
- Files:
-
- MakeLink Binary
- MakeLink.c Source code. Do not link with startup modules.
- MakeLink.doc This file!
- SCOPTIONS SAS/C 6.x SCOPTIONS; just type sc makelink.c
-
- Template:
-
- FROM/A,TO/A,HARD/S,FORCE/S,SOFT/S
-
- Usage:
-
- makelink <from> <to> [hard] [force] [soft]
-
- Options:
-
- FROM:
- This is the name of the link to create.
-
- TO:
- This is the file/directory to link to. If this is a soft link, this
- should be either an absolute path or a path relative to the FROM's
- directory. If this is a hard link, this can be any path as it is
- resolved at makelink-time.
-
- HARD:
- This switch is basically ignored, but produces an error if you specify
- it and SOFT at the same time. The default is hard links unless you
- specify SOFT.
-
- FORCE:
- This switch must be supplied to create a hard link to a directory.
- NOTE about hard links to dirs! Many directory utilities, DirWork among
- them, will recognize link-dirs as real directories, and if you hit the
- recursive-delete button, it will traverse the directory. However, the
- CLI Delete command handles directory hard links properly (it will delete
- the link only).
-
- SOFT:
- Specify this option to make a soft link. In this case, the keyword
- FORCE is ignored.
-
- Revision History:
-
- 42.1 (16-Nov-94):
- Internal release. Used version 42.x because this is the popular version
- number for 3.1-compatible commands and utilities of the same name.
-
- 42.2 (18-Nov-94):
- First public release.
- Fixed hard link Enforcer hit. Not checking the return value of Lock()
- and attempting to Examine() NULL. :-P
-
- The Author:
-
- Todd Vierling (amigagod@grove.ufl.edu).
- As of November 1994 this e-mail address is correct.
- Also, browse me on the WWW: http://grove.ufl.edu/~amigagod/
-