From owner-freebsd-questions Sun Feb 16 15: 4:28 2003 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 C721737B401 for ; Sun, 16 Feb 2003 15:04:27 -0800 (PST) Received: from hotmail.com (f146.pav2.hotmail.com [64.4.37.146]) by mx1.FreeBSD.org (Postfix) with ESMTP id BC3A943FAF for ; Sun, 16 Feb 2003 15:04:26 -0800 (PST) (envelope-from howcanthisbe300@hotmail.com) Received: from mail pickup service by hotmail.com with Microsoft SMTPSVC; Sun, 16 Feb 2003 15:04:26 -0800 Received: from 80.132.146.15 by pv2fd.pav2.hotmail.msn.com with HTTP; Sun, 16 Feb 2003 23:04:26 GMT X-Originating-IP: [80.132.146.15] From: "How Can ThisBe" To: freebsd-questions@FreeBSD.ORG Subject: sed question Date: Sun, 16 Feb 2003 23:04:26 +0000 Mime-Version: 1.0 Content-Type: text/plain; format=flowed Message-ID: X-OriginalArrivalTime: 16 Feb 2003 23:04:26.0706 (UTC) FILETIME=[C0C93320:01C2D60F] Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Not directly FreeBSD question, however. Is it possible with sed (or awk) to turn this: i/in/1 2/3 4 5 6 into i/in/1 2/3456 The same syntax would also need to work on: i/in/1 2/x y z (result would be i/in/1 2/xyz) i/in/1 2 (result would be i/in/12) The closest I have gotten it to is: i/in/1 2/3 4 56 with sed "s/\(.*\) /\1/g" (which will work, just needs to be repeated. I do not know awk at all btw) _________________________________________________________________ Hotmail now available on Australian mobile phones. Go to http://ninemsn.com.au/mobilecentral/hotmail_mobile.asp To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message