🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.mail.mush
Article #619

compressed folders

#619
From: Chadley Kaye Dawson
Date: Mon, 05 Oct 1992 15:31
66 lines
2199 bytes

Here's some cmd`s I wrote to automate the compression/
decompression of folders. It compresses all but the
"%" folder which I keep uncompressed so incoming mail
can be handled outside of mush. 


# To compress a folder

cmd com 'pipe compress ~/mailfolders/!*'

# To store the current (soon to be old) folder name

cmd olf 'eval -p set oldfolder= %f'

# To compress the oldfolder

cmd como 'com $oldfolder'

# To uncompress a folder

cmd ucom 'pipe uncompress ~/mailfolders/!*'

# The new "folder" command to switch to a new folder:
# First it stores the name of the current folder,
# then it uncompress the new folder, switches to the
# new folder, and finally compress the oldfolder.

cmd f 'olf ; ucom !* ; folder +!* ; como'

# This command takes you to you home %, mailfolder
# It is similar to the f command above, but does not
# try to un/uncompress the home folder.

cmd home 'olf ; folder % ; como'

# This new move command is necessary to save messages into
# compressed folders. It first uncompresses the target
# folder, then saves the messages into it, then recompresses
# the folder and finally deletes the messages.

cmd m 'ucom !:2 ; save !:1 +!:2 ; com !:2 ; d !:1'


Ex 1: to switch to mailfolder "meetings"

mush>f meetings

Ex 2: To return to incoming mail folder

mush> home

Ex 3: To move messags 13,16 and 20-23 to folder "meetings"

mush> m 13,16,20-23 meetings

Caveats: These commands assume that the folders are compressed.
         If in Ex 3, the "meetings" folder did not exist, error
         messages about not being able to uncompress the folder
         come up on the screen, but the command still works.


Any ideas on how to get rid of the error messages? Thanks,

-chad dawson
Technical Details
Message-ID: <geo5zI200jWRI1bQt8@andrew.cmu.edu>
Path: arc1-ca.pugleaf.net!sparky!uunet!sun-barr!olivea!spool.mu.edu!wupost!darwin.sura.net!udel!rochester!cantaloupe.srv.cs.cmu.edu!crabapple.srv.cs.cmu.edu!andrew.cmu.edu!cd1f+

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!sun-barr!olivea!spool.mu.edu!wupost!darwin.sura.net!udel!rochester!cantaloupe.srv.cs.cmu.edu!crabapple.srv.cs.cmu.edu!andrew.cmu.edu!cd1f+
From: cd1f+@andrew.cmu.edu (Chadley Kaye Dawson)
Newsgroups: comp.mail.mush
Subject: compressed folders
Message-ID: <geo5zI200jWRI1bQt8@andrew.cmu.edu>
Date: 5 Oct 92 15:31:32 GMT
Organization: Psychology, Carnegie Mellon, Pittsburgh, PA
Lines: 66