🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.readers
Article #242055

fill-paragraph in USENET messages (was: Quotelength with slrn and vim)

#242055
From: Adam Funk
Date: Mon, 09 Aug 2010 19:21
41 lines
2861 bytes
[I'm adding gnu.emacs.help in case this is useful to someone outside
of NSR --- please feel free to prune FUs.]

On 2010-08-08, Adam Funk wrote:

> If I put the cursor in a section of text with a blank line before and
> after it, and press M-q, emacs will reformat ("fill") it and preserve
> the number of ">" at the beginning of each line --- which I've just
> done to your lines above.  Unfortunately, it doesn't correctly
> identify the "paragraph" to reformat if there are non-blank lines
> containing only ">" and spaces that make it contiguous with other
> paragraphs with different levels of quoting.


Well, I just found the following in my ~/.emacs file 

#v+
;; Message-ID: <mailman.1142.1174348863.7795.help-gnu-emacs@gnu.org>
;; From: Matthew Flaschen <matthew.flaschen@gatech.edu>
;; gnu.emacs.help  2007-03-19
;; Subject: Re: Configuring fill-paragraph not to mash the subversion delimiter?
(setq paragraph-start (concat paragraph-start "\\|--This line, and those below, will be ignored--"))
(setq paragraph-separate (concat paragraph-separate "\\|--This line, and those below, will be ignored--"))
#v-

and thought I might be able to string something together to deal with
adjacent quoted text in news posts.

#v+
(setq paragraph-start (concat paragraph-start "\\|[> \t]*\\(-- *\\)?$"))
(setq paragraph-separate (concat paragraph-start "\\|[> \t]*\\(-- *\\)?$"))
#v-

That seems to do what I want, but I welcome improvements.


-- 
The three-martini lunch is the epitome of American efficiency.
Where else can you get an earful, a bellyful and a snootful at
the same time?                             [Gerald Ford, 1978]
Technical Details
Message-ID: <b316j7x3a5.ln2@news.ducksburg.com>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!mbox2nntp-gnu.emacs.help.mbox.zip!g2news1.google.com!news2.google.com!newsfeed2.dallas1.level3.net!news.level3.com!newsfeed-00.mathworks.com!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail
References: <slrni5qtcf.d1a.houghi@penne.houghi> <slrni5r251.hdt.steve@sorceror.wizard.dyndns.org> <slrni5r2nb.d1a.houghi@penne.houghi> <slrni5tfii.ob5.catwheezel@ID-107770.user.individual.net> <1mg3j7xuou.ln2@news.ducksburg.com>

Show Full Headers
Complete Article Headers
Message-ID: <b316j7x3a5.ln2@news.ducksburg.com>
Subject: fill-paragraph in USENET messages (was: Quotelength with slrn and vim)
Date: Mon, 09 Aug 2010 20:21:47 +0100
From: Adam Funk <a24061@ducksburg.com>
References: <slrni5qtcf.d1a.houghi@penne.houghi> <slrni5r251.hdt.steve@sorceror.wizard.dyndns.org> <slrni5r2nb.d1a.houghi@penne.houghi> <slrni5tfii.ob5.catwheezel@ID-107770.user.individual.net> <1mg3j7xuou.ln2@news.ducksburg.com>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!mbox2nntp-gnu.emacs.help.mbox.zip!g2news1.google.com!news2.google.com!newsfeed2.dallas1.level3.net!news.level3.com!newsfeed-00.mathworks.com!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail
Newsgroups: news.software.readers,gnu.emacs.help
Organization: $CABAL
Lines: 40
X-Trace: individual.net nm+mRn9XTTHoAkMb5805nQcU6hDpwEg6mlluDDVVW/pMUMHyqJ
X-Orig-Path: news.ducksburg.com!not-for-mail
Cancel-Lock: sha1:+WDIjBqu7JzDeymX857nOO5TsBM= sha1:Hcm3NsxnPJ3CF8PF2gXKbDobQJo=
User-Agent: slrn/pre1.0.0-16/mm/ao (Ubuntu Intrepid)