🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.readers
Article #150812

Re: [XNEWS] How to save tread in one txt file?

#150812
From: Guy
Date: Sun, 27 Jun 2004 22:30
41 lines
3173 bytes
Michael Drach wrote:

> I have asked this question even before but I don't think I got
> straight answer. Is it possible to save selected messages from a
> thread in one text file with desired header information included?
> For example only FROM, SUBJECT and DATE fields! 
> How am I supposed to do so? 
> 

Save the messages to one file then "grep -v" them out.

Ready?[*] You need Grep and to create a PATTERN file.

Highlight the collapsed thread, Article > Save As (or press F6).
Change the filename "Auto" to something like "saved.txt".
Open "saved.txt" in an editor and determine which headers you want
to remove. Put them in a PATTERN file i.e. "remove.dat" as one long
string with a backslash and a pipe(\|) between each.

PROMPT>type saved.txt | grep -v -f remove.dat - > saved.txt

Open the new "saved.txt" file and check, you may need to add more
headers to the PATTERN file, if so add them and run the command again.
Be wary to only match headers and not any body text.

I just tried the above method with the 30 post thread entitled:
"[Xnews] How can I use fonts, colors, bolding, etc. when composing?"
and it cleanup just fine.

Example PATTERN file(remove.dat):
>From ???\|Path\|Newsgroups\|References\|Organization\|Reply-To\|Mime-Version\|Lines\|Message-ID\|NNTP-Posting\|Content-Type\|Content-Transfer-Encoding\|X-Newsreader\|X-Orig\|X-Trace\|X-Complain\|User-Agent\|X-Face\|Xref\|X-DMCA\|X-Abuse\|X-Postfilter\|X-No-Archive\|Archive:\|Distribution:\|Mail-Copies-To\|X-Sent-From 


  [*] Probably not! ;~)

-- 
Regards,
Guy

Xnews "XP" Icon Patcher Files
<http://xnews-icon-patchers.bebto.com/patcher.html>
Technical Details
Message-ID: <9515B20CE61882E284CEEC009E394A9D7@127.0.0.1>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.20140922.mbox.gz!number1.nntp.dca.giganews.com!internal1.nntp.sjc.giganews.com!border2.nntp.sjc.giganews.com!nntp.giganews.com!cyclone-sf.pbi.net!216.218.192.242!news.he.net!newsfeed1.easynews.com!easynews.com!easynews!newsfeed3.dallas1.level3.net!newsfeed2.dallas1.level3.net!news.level3.com!newsfeed.mathworks.com!fu-berlin.de!uni-berlin.de!not-for-mail
References: <Xns951583677C650mursa5hotmailcom@161.53.2.66>

Show Full Headers
Complete Article Headers
Message-ID: <9515B20CE61882E284CEEC009E394A9D7@127.0.0.1>
Subject: Re: [XNEWS] How to save tread in one txt file?
Date: Sun, 27 Jun 2004 17:30:11 -0500
From: Guy <Use-Reply-To-Address-Header@[127.1]>
References: <Xns951583677C650mursa5hotmailcom@161.53.2.66>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.20140922.mbox.gz!number1.nntp.dca.giganews.com!internal1.nntp.sjc.giganews.com!border2.nntp.sjc.giganews.com!nntp.giganews.com!cyclone-sf.pbi.net!216.218.192.242!news.he.net!newsfeed1.easynews.com!easynews.com!easynews!newsfeed3.dallas1.level3.net!newsfeed2.dallas1.level3.net!news.level3.com!newsfeed.mathworks.com!fu-berlin.de!uni-berlin.de!not-for-mail
Newsgroups: news.software.readers
Organization: none
Lines: 41
Reply-To: GuysAlias <AT> myrealbox <DOT> com
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
X-Trace: news.uni-berlin.de 4t1iAWr2dtoeuL3rb6ELFQxG8HQdvPUVpmrgwlIszkRW1rCag=
User-Agent: Xnews/06.08.25
X-No-Archive: yes
Archive: No
X-0: "Whoever would overthrow the liberty of a nation must begin by subduing
 the freeness of speech." -- Benjamin Franklin
X-Face: ,O=kHpT4ofN[ZQ?pgJ6BQtX(cJvPRNtp'pID9gnUbjs4F3yd0#\GOd'S;
 U@<[Y6X*V`vh.)v%U'IaXUBq/F9,m,P; HY{n-Q[V0"+>u5W`Zf&[c;
 34vOB1T~&wE<'yA(Eg7V,W,Sk_gd0JPg1E$,J&X}SN-51Hwg; )hM/Ttq$Um2Kq$u