From owner-freebsd-hackers Tue Jul 25 15:15:36 1995 Return-Path: hackers-owner Received: (from majordom@localhost) by freefall.cdrom.com (8.6.11/8.6.6) id PAA15180 for hackers-outgoing; Tue, 25 Jul 1995 15:15:36 -0700 Received: from eikon.regent.e-technik.tu-muenchen.de (eikon.regent.e-technik.tu-muenchen.de [129.187.42.3]) by freefall.cdrom.com (8.6.11/8.6.6) with SMTP id PAA15156 for ; Tue, 25 Jul 1995 15:15:14 -0700 Received: from vector.eikon.e-technik.tu-muenchen.de ([129.187.142.36]) by eikon.regent.e-technik.tu-muenchen.de with SMTP id <55305>; Wed, 26 Jul 1995 00:14:12 +0200 Received: (from jhs@localhost) by vector.eikon.e-technik.tu-muenchen.de (8.6.11/8.6.9) id XAA16044 for hackers@freebsd.org; Tue, 25 Jul 1995 23:52:51 +0200 Date: Tue, 25 Jul 1995 23:52:51 +0200 From: Julian Howard Stacey Message-Id: <199507252152.XAA16044@vector.eikon.e-technik.tu-muenchen.de> To: hackers@freebsd.org Subject: mailmerge functionality - suggestions welcome Sender: hackers-owner@freebsd.org Precedence: bulk Hi Hackers, Before I reinvent the wheel, I'd welcome suggestions ... What would be our best tools to achieve the following I want to send out a load of letters & faxes, & need a `mailmerge' type of functionality. What I have is something like this: }{ Acme Inc Mr Fred Customer Some street some place Tel 1234 Fax 5678 My supplier number 1234abcd \" Last contacted them 7/95, they only buy cheap, }{ Foo Bar & Associates Mrs Jane Dough Some Avenue Metropolis Tel 87643 Fax They have one but I dont know the number Email: broken@unknown.host.com 10 Long line of .......... chatty extra text/notes }{ I need tools to iterate through a (tidied up) version (& maybe even sort it), splitting each line in a set of transient seperate mini files: adr1 adr2 adr3 adr4 company fax name1 name2 reference and calling a ./doit shell, that will invoke my existing BSD makefiles, that in turn invokes nroff &/or make + sendfax, with stuff like .so var/name1 and FAX_TO_NAME ="`cat var/name1`" I could use an /etc/passwd `:' delimited type format, & parse it with awk, but that's too unwieldy to maintain with vi, as each of the blocks above would compact to a single long (too long) line. I'm quite happy to edit the input format, & write some C, but before I go reinventing the wheel .... Any suggestions of tools ? Thanks Julian S. jhs@freebsd.org