in reply to Want to do One line Perl Command

Here's a different approach:
perl -0ne 'unlink /.+\n(?:Errors$)+|(.+)/mg'

Replies are listed 'Best First'.
Re^2: Want to do One line Perl Command
by muba (Priest) on Jul 05, 2004 at 11:08 UTC
    Hmm... I just don't see why it's so important to you to have a perl -ne style one-liner. What's wrong with a script which can do the job easier and more readable than a one-liner?
    "2b"||!"2b";$$_="the question"