in reply to Re: match and then delete next line
in thread match and then delete next line

Doesn't that double print lines matching following /pattern/?

Perhaps you meant something like ...

perl -pi.bak -e '/^pattern$/ && <>' a_text_file.txt

...where the <> eats up the next line before it gets assigned to $_ and printed by the -p switch.

Update: s/matching/following/;, but it took me a while to figure out why. Neat trick!++ :)

    --k.