Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com From: "Rob" To: "Cygwin" Subject: Edit file Date: Sat, 12 Jan 2002 00:48:18 +1100 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0) X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 Importance: Normal Howdy! I would like to make a script that can change a line in a file.. commenting out a line in a java source file to be precise. I would like to look for this line: import visualiser.HostIDVPatcher; and edit it to this: // import visualiser.HostIDVPatcher; Can I do this? I tried using sed with this line: cat visualiser/PositionData.java | s/import visualiser.HostIDVPatcher;/\/\/import visualiser.HostIDVPatcher;/ | out.txt and this was what I got: :-] -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/