Article View: news.software.nn
Article #7925Improved Decoding for NN
From: Frank Pilhofer
Date: Thu, 05 Sep 1996 00:00
Date: Thu, 05 Sep 1996 00:00
120 lines
5565 bytes
5565 bytes
Hi Folks,
Some time ago I had posted a patch to nn to use the powerful decoding
functions provided by the UUDeview Decoding Library. I have now updated
the patch. The decoding is now even more comfortable to handle, and I've
even built in the reverse: you can now attach files to your newsgroup
postings, which will be sent as proper MIME multipart messages.
The UUDeview Library provides support for decoding uuencoded, Base64
and BinHex-encoded files. With it's own part sorting and threading, you
do not need to bother about what articles to select.
See below for a full list of features.
The following patch applies to nn 6.5.1. Here's how to integrate
the patch:
o Patch your nn sources. Extract the file below, go to your nn
source directory and type:
gzcat nn-6.5.1-uudeview.diff.gz | patch -p1
If the changes to "Makefile" fail because of your own changes,
edit the following two lines manually:
CFLAGS = -O -Iuulib
LDFLAGS = -Luulib -luu
(the distribution Makefile has no "LDFLAGS" line. Just add it.)
o Download the UUDeview package. The most recent version is 0.5.7,
available as uudeview-0.5.7.tar.gz or from its home page,
http://www.uni-frankfurt.de/~fp/uudeview/
(Version 0.5.7 is _required_ for the attachment feature to work,
the decoding will also work with older versions).
o Extract, compile and install UUDeview so that the binaries are
globally accessible. Do not remove the source yet.
o Go to your nn sources and create a symbolic link to UUDeview's
"uulib" subdirectory:
ln -s /where/ever/uudeview-0.5.5/uulib .
o The file config.h-dist has also been modified by the patch. If
you already had nn properly configured, save a copy of your
custom config.h and follow the nn configuration instructions
again.
The new entry in config.h-dist defines the location of the
"uuenview" program (yes, uu*en*view, not uudeview). This is
necessary for the attachment feature to work.
o Compile and install nn as usual. If you have an existing
installation, there's no need to remake nnmaster (just do
"make client").
The decoding feature:
---------------------
Instead of changing the behaviour of ":decode", I added another command
":deview" which invokes the new code. In the unlikely event that UUDeview
screws up, you can still escape to the old :decode.
Handling the new function is easy. Select all articles with encoded data
and hit :deview. You will be asked for a target directory to write the
decoded files to. This works even if parts of one file are mixed with
parts of other files, so in a binaries group you could just hit =. to
select all articles and then :deview everything.
All articles will be scanned for encoded data. You will then be asked
for each file wheter it shall be decoded or not. At the prompt, answer
'q' to abort the procedure, 'n' to not decode this file, 'a' to decode
all futher files without promting and 'y' (or any other key) to decode
this single file.
The attachment feature:
-----------------------
You know the prompt you see when posting an article after you've
written it. At that point, you now have the new choice "at)tach".
If you choose it, you will be asked to enter the name of a file
to be attached. You can repeat this step as often as you like.
After you've finally agreed to "p)ost" the article, it will be
sent with all files as separate attachments.
Currently, all attachments are encoded in Base64 format.
Because nn jumps to the editor first and aborts if you don't edit
anything, it is not possible to send a blank message with attach-
ments (which isn't necessary as uuenview can handle that job, too).
I hope there are people out there who will find the patch useful. Let
me know. I'm also goint to try and make a similar patch to elm (based
on version 2.4.25). However, I'm still at the learning stage there,
elm's sources aren't the easiest to read.
Have fun,
Frank
begin 644 nn-6.5.1-uudeview.diff.gz
<uuencoded_portion_removed>
A1LD=E\GG_4W[JZ6=SL1B@\+F6D,%2MW_`)B5R+-='```
`
end
--
+ Frank Pilhofer fp@informatik.uni-frankfurt.de +
| Darmstaedter Str. 22 http://www.uni-frankfurt.de/~fp/ |
| D-63225 Langen, Germany RAD Host |
+---------------------------------------------------------------------------+
| It's no use. She'll never see me as anything - but a monster. The Beast |
--
+ Frank Pilhofer fp@informatik.uni-frankfurt.de +
| Darmstaedter Str. 22 http://www.uni-frankfurt.de/~fp/ |
| D-63225 Langen, Germany RAD Host |
+---------------------------------------------------------------------------+
| It's no use. She'll never see me as anything - but a monster. The Beast |
Technical Details
Message-ID:
<DxA8EI.Dy@rose.fpp.tm.informatik.uni-frankfurt.de>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nn.mbox.zip!not-for-mailShow Full Headers
Complete Article Headers
Message-ID: <DxA8EI.Dy@rose.fpp.tm.informatik.uni-frankfurt.de> Subject: Improved Decoding for NN Date: Thu, 05 Sep 1996 00:00:00 +0000 From: fp@rose.fpp.tm.informatik.uni-frankfurt.de (Frank Pilhofer) Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nn.mbox.zip!not-for-mail X-Deja-AN: 178831557 Organization: Frank Pilhofer Projects Network Newsgroups: news.software.nn