From owner-freebsd-questions@FreeBSD.ORG Tue Sep 28 17:59:35 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4932116A4CE for ; Tue, 28 Sep 2004 17:59:35 +0000 (GMT) Received: from sage.thought.org (dsl231-043-140.sea1.dsl.speakeasy.net [216.231.43.140]) by mx1.FreeBSD.org (Postfix) with ESMTP id B41D643D2D for ; Tue, 28 Sep 2004 17:59:34 +0000 (GMT) (envelope-from kline@tao.thought.org) Received: from thought.org (tao [10.0.0.247]) by sage.thought.org (8.12.10/8.12.10) with ESMTP id i8SHx1h0016531; Tue, 28 Sep 2004 10:59:03 -0700 (PDT) (envelope-from kline@tao.thought.org) Received: from tao.thought.org (localhost [127.0.0.1]) by thought.org (8.12.11/8.12.11) with ESMTP id i8SHxPnQ002680; Tue, 28 Sep 2004 10:59:25 -0700 (PDT) (envelope-from kline@tao.thought.org) Received: (from kline@localhost) by tao.thought.org (8.12.11/8.12.11/Submit) id i8SHxOeU002679; Tue, 28 Sep 2004 10:59:24 -0700 (PDT) (envelope-from kline) Date: Tue, 28 Sep 2004 10:59:23 -0700 From: Gary Kline To: Fabian Keil Message-ID: <20040928175923.GC2525@thought.org> References: <20040927192859.GA82254@thought.org> <200409281253.12887.freebsd-listen@fabiankeil.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200409281253.12887.freebsd-listen@fabiankeil.de> X-Organization: Thought Unlimited. Public service Unix since 1986. X-Of_Interest: Observing 18 years of service to the Unix community User-Agent: Mutt/1.5.6i cc: Gary Kline cc: freebsd-questions@freebsd.org Subject: Re: regex replacement wizard advice needed X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 28 Sep 2004 17:59:35 -0000 On Tue, Sep 28, 2004 at 12:53:12PM +0200, Fabian Keil wrote: > On Monday 27 September 2004 21:28, Gary Kline wrote: > [[ ... ]] > > 747
> > Paragraph747. > > I'd rather take something like: > > (echo "Title

Title

    "; > perl -n -e 's@^\d+\s+(.*$)@
  1. $1

  2. @;print' input.txt; > echo "
") >output.html > > Without the line breaks, of course. > This might be closer, plugging in your ";print" and Tom's regex, since the doc is plaintext, maybe ASCII. But then I'll want to put

or
tags before each (\d+) line. Your echo lines are great for turning text into HTML; save some typing. Thanks for the idea. gary > Semantic markup and valid HTML 2.0. > > Regards > Fabian > > > > > -- Gary Kline kline@thought.org www.thought.org Public service Unix