Date: Thu, 20 Jun 2002 15:10:03 -0700 (PDT) From: Oliver Braun <obraun@informatik.unibw-muenchen.de> To: freebsd-bugs@FreeBSD.org Subject: Re: bin/39599: sed -i -e '[...]' file saves backup file with extension -e Message-ID: <200206202210.g5KMA3e85747@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/39599; it has been noted by GNATS. From: Oliver Braun <obraun@informatik.unibw-muenchen.de> To: Matthew Hunt <mph@astro.caltech.edu> Cc: FreeBSD-gnats-submit@FreeBSD.ORG Subject: Re: bin/39599: sed -i -e '[...]' file saves backup file with extension -e Date: Thu, 20 Jun 2002 23:35:59 +0200 * Matthew Hunt <mph@astro.caltech.edu> [2002-06-20 23:30]: > On Thu, Jun 20, 2002 at 11:00:26PM +0200, Oliver Braun wrote: > > If sed(1) is called with -i flag without an extension the following characters > > will be used as extension. man sed says: If a zero-length extension is given, > > no backup will be saved. > I think you actually need to provide the zero-length extension: > sed -i "" -e 's/foo/bar/g' filename OK. I see. I think I have missunderstood the manpage. I assumed that a zero-length extension == no extension. => This PR can be closed. Regards, Olli To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200206202210.g5KMA3e85747>