This is one of those odd commands that somehow make their way into standard distributions. Its obvious intent is to wait for some file system to mount: it just sleeps and doesn't return until it is. You can't really use it for ordinary directory watching (see Monitoring file or directory changes below if you need that) because it only checks when the mount table is updated. So you can do "wait4path /not_here_yet" and it will sleep, but it won't wake up and return just because you "mkdir /not_here_yet". If you subsequently mount or unmount any file system, it will wake up and notice /not_here_yet, but not until then.
Therefor its obvious use is in a startup script that needs to hang on until some specific filesystem is mounted. Is it actually used in OS X? Well, not on my MacBook, but there's nothing being mounted there it would need to wait for. If I had a server here, and user's directories were there, maybe it would make use of this.
You could use this as a cheap notification of mount/unmount events:
Though at the moment I can't think of a good reason that would make you want to.
Got something to add? Send me email.
(OLDER) <- More Stuff -> (NEWER) (NEWEST)
Printer Friendly Version
Increase ad revenue 50-250% with Ezoic