# Explanation of pof and Friends

The Section Folder Stacks gives an overview of this package. Here is the pof script (you might want to open it in a separate browser window). To install it, see the Section Programs in This Book's Archive.

pof is a script with many links (names): puf, lsf, clrf, and pof1, pof2, ..., through pof8. If you install it from the archive file, give all these link names to tar and it will create the links automatically. If you get the individual pof file, use ln to make the links by hand.

The script isn't very complicated, though you'll need to be fairly familiar with Bourne Shell programming to catch some of it. For instance, the script uses the command-line parameters to store the folder stack -- like this:

        set x `folder -list`; shift

After that command, `$1` contains the current folder (the "front" or "left-hand side" of the folder -list output). `$2` has the second word in that list: the top of the folder stack. `$*` has the entire list. And so on.

One other thing worth mentioning: for efficiency, I used as many built-in Bourne shell commands as I could. For instance, the UNIX expr command (for counting) isn't built in, so the script uses a shell variable with a list of numbers. Users with slow computers will (hopefully) appreciate this slightly-kludgey code.