9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: Matthias Teege <matthias-9fans@mteege.de>
To: 9fans@cse.psu.edu
Subject: [9fans] regexp to match paragraphs in troff documents
Date: Thu,  7 Jun 2007 14:28:37 +0000	[thread overview]
Message-ID: <082ffdbcfda12b51637105e95ea479c8@mteege.de> (raw)

Moin,

I've tried to pipe paragraphs of a troff document to fmt but I
have problems with the correct regular expression. My first attempt
"/^\.[A-Z]++.*\n(^[^]*)*\n^\.[A-Z]++.*\n/" matches only any second
paragraph because the expression is overlapping. Does anyone have a nice
idea to match troff parapgraphs?

Many thanks
Matthias



             reply	other threads:[~2007-06-07 14:28 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-07 14:28 Matthias Teege [this message]
2007-06-07 14:50 ` rog
2007-06-07 17:46 ` Russ Cox

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=082ffdbcfda12b51637105e95ea479c8@mteege.de \
    --to=matthias-9fans@mteege.de \
    --cc=9fans@cse.psu.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).