[comp.mail.mush] zfolder

schaefer@CSE.OGI.EDU (Barton E. Schaefer) (02/03/90)

On Feb 2, 10:02am, Renato De Leone wrote:
} Subject: zfolder
} 
} I found some problem using zfolder and folder. It seems to me that the
} variable compress is not unset when folder command is called (instead
} of zfolder)
} 
} In other words, if I uncompress a folder using zfolder and then i
} return to (say) /usr/spool/mail/... using folder and then I call again
} zfolder I lose the content of /usr/spool/mail/...

First of all, you shouldn't actually have lost anything -- the content
of /usr/spool/mail is now compressed into the file that you originally
loaded with zfolder, and the file you loaded with zfolder is probably
still sitting out there in the temporary file [although it may (ouch)
have been overwritten by the second zfolder :-( ]

If you uncompress with zfolder and then change elsewhere with folder you
also don't get your zfolder'd file re-compressed.  zfolder will work with
an "ordinary" folder as long as there is not a compressed one with the
same name -- that is, after uncompressing with zfolder, you can change
to a your spool folder by using "zfolder %".  (Hopefully you don't have
any files named "%.Z" sitting around in your current directory.)

If you really want "folder" to work `between' zfolders, you'll have to do
two things:

    1.  cmd folder 'unset compress; \folder'	# note backslash
	cmd fo folder

    2.  Change all uses of "folder" in the .zfolder script to
	be \folder (so the folder cmd won't be used).

But that still doesn't get the compressed version updated.  Hmm, I'm
getting an idea ... maybe I'll repost a modified .zfolder later ....

Note also that you shouldn't change directories when using zfolder,
because the $compress variable does not necessarily contain an absolute
path, and that there is no way to use an uncompressed folder in "read
only" mode (zfolder -r does not work).

As an aside, I just found a "bug" in file completion.  Don't try to
file-complete % or & just yet, ok? :-}

I better start putting "no warranties expressed or implied" on my
postings .....

-- 
Bart Schaefer                             "Live and don't learn, that's us."
                                                                   -- Hobbes

schaefer@cse.ogi.edu (used to be cse.ogc.edu)