From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13720 invoked by alias); 20 Feb 2004 07:02:06 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 13709 invoked from network); 20 Feb 2004 07:02:05 -0000 Received: from unknown (HELO hobbit.corpit.ru) (81.13.94.6) by sources.redhat.com with SMTP; 20 Feb 2004 07:02:05 -0000 Received: from corpit.ru (paltus.tls.msk.ru [192.168.1.1]) by hobbit.corpit.ru (Postfix) with ESMTP id 2B98A29480 for ; Fri, 20 Feb 2004 10:02:04 +0300 (MSK) (envelope-from deo@corpit.ru) Message-ID: <4035B0EB.50003@corpit.ru> Date: Fri, 20 Feb 2004 07:33:00 -0000 From: Egor Duda User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040122 Debian/1.6-1 MIME-Version: 1.0 To: cygwin@cygwin.com Subject: Re: search and replace tool References: <291592011.20040218205953@thequod.de> <6.0.1.1.0.20040218151724.0398d488@127.0.0.1> <40354B21.6040802@x-ray.at> <40355763.E01A2710@dessent.net> In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2004-02/txt/msg01034.txt.bz2 > On Thu, 19 Feb 2004, Brian Dessent wrote: >>>What on Earth are you talking about? What inability? WFM (see below). >>>... >>>$ perl -i -pe 's/blah/stuff/g' sometext >>>$ ls >>>sometext sometext.bak >> >>It didn't do the editing "inline", it created a new file and renamed the >>old one ".bak". In other words, on Cygwin "-i" is really "-i.bak". If >>you try the above sequence on linux you don't get a .bak file and the >>changes are truly done in-place. I assume this relates to differences >>in filesystem semantics. huh? what do you mean "in-place"? linux writes new file to new place, it just deletes .bak file afterwards, unlike cygwin. deo@paltus:~$ echo aaa >xxx deo@paltus:~$ ls -i xxx 408096 xxx deo@paltus:~$ perl -i -pe 's/aaa/bbbb/' xxx deo@paltus:~$ ls -i xxx 408074 xxx deo@paltus:~$ cat xxx bbbb egor. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/