From owner-freebsd-questions@FreeBSD.ORG Thu Jan 15 19:24:50 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 43AFA16A4CE for ; Thu, 15 Jan 2004 19:24:50 -0800 (PST) Received: from plewe.is.tsukuba.ac.jp (plewe.is.tsukuba.ac.jp [130.158.81.199]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7B99C43D67 for ; Thu, 15 Jan 2004 19:24:48 -0800 (PST) (envelope-from till@plewe.is.tsukuba.ac.jp) Received: from plewe.is.tsukuba.ac.jp (localhost [127.0.0.1]) i0G3Qqac041424; Fri, 16 Jan 2004 12:26:52 +0900 (JST) (envelope-from till@plewe.is.tsukuba.ac.jp) Received: (from till@localhost) by plewe.is.tsukuba.ac.jp (8.12.10/8.12.10/Submit) id i0G3Qq3s041423; Fri, 16 Jan 2004 12:26:52 +0900 (JST) (envelope-from till) Date: Fri, 16 Jan 2004 12:26:52 +0900 From: Till Plewe To: Evan Sayer Message-ID: <20040116032652.GA41221@plewe.is.tsukuba.ac.jp> References: <29AAE3F4-47D1-11D8-946B-000A95CCF8C4@san.rr.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <29AAE3F4-47D1-11D8-946B-000A95CCF8C4@san.rr.com> User-Agent: Mutt/1.5.4i-ja.1 cc: freebsd-questions@freebsd.org Subject: Re: your mail X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: till@score.is.tsukuba.ac.jp List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Jan 2004 03:24:50 -0000 On Thu, Jan 15, 2004 at 07:07:48PM -0800, Evan Sayer wrote: > FreeBSD- > Please help, this is really important. I was told that i could get rid > of the ^m symbols at the end of the lines in my web page's html code > by using sed. They said to execute sed "s//^m^m" index.html > > index.html or something like that. This got rid of everything in the > file. I really need this back, so any help would be greatly > appreciated. > Unless you have a back up your file is lost. If you type: command FILE1a ... FILE1z > FILE2 in your shell, then the shell does the following: 1) it creates an empty file with name FILE2. If there is already a file with this name it will be !ERASED! 2) it executes the command using FILES1a-FILE1z as arguments 3) writes the result into FILE2. In your case the shell erased your file "index.html" before it could use it as an argument to the sed command. Sorry. - Till