From owner-freebsd-questions@FreeBSD.ORG Tue Jun 21 15:30:16 2011 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8C661106564A for ; Tue, 21 Jun 2011 15:30:16 +0000 (UTC) (envelope-from matt@conundrum.com) Received: from coke.conundrum.com (coke.conundrum.com [216.235.9.139]) by mx1.freebsd.org (Postfix) with ESMTP id 54F618FC16 for ; Tue, 21 Jun 2011 15:30:15 +0000 (UTC) Received: from chani.conundrum.com (chani.conundrum.com [216.235.10.34]) by coke.conundrum.com (8.13.1/8.12.6) with ESMTP id p5LFTw7l055563; Tue, 21 Jun 2011 11:29:58 -0400 (EDT) (envelope-from matt@conundrum.com) Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: text/plain; charset=us-ascii From: Matthew Pounsett In-Reply-To: Date: Tue, 21 Jun 2011 11:29:53 -0400 Content-Transfer-Encoding: quoted-printable Message-Id: References: <73E783DC-E32B-4DE3-AFF6-4A75D1D3A00A@conundrum.com> To: Lars Kellogg-Stedman X-Mailer: Apple Mail (2.1084) Cc: freebsd-questions@freebsd.org Subject: Re: sed argument processing b0rked? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 21 Jun 2011 15:30:16 -0000 On 2011/06/21, at 11:24, Lars Kellogg-Stedman wrote: >>> sed -i'' -e 's/^\(REVOKE ALL ON SCHEMA public FROM = \)postgres/\1pgsql/' \ >> ? -e 's/^\(GRANT ALL ON SCHEMA public TO = \)postgres/\1pgsql/' \ >> ? /tmp/pgdump >> sed: -e: No such file or directory >=20 > If you put a space after -i: >=20 > sed -i '' ... Aha... I knew it had to be something. I couldn't quite wrap my head = around the idea that sed is misbehaving.. it seems way too old and set = in its ways for that. However, I did get the -i'' syntax from = somewhere.. perhaps it's a GNUism and I just forgot where I picked it = up. =20 Thanks for the correction!=