in reply to Add blank line between two consecutive lines starting with specified strings
It is certainly possible. Assuming Windows command line (update: and assuming "black" means "blank"), try (semi-tested):
perl -wMstrict -pe "BEGIN { our $armed } $::armed = /\A \\macroa \s/x +? 1 : /\A \\macrob \s/x && $::armed && ! print qq{\n}" infile > outfi +le
Give a man a fish: <%-{-{-{-<
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Add blank line between two consecutive lines starting with specified strings
by texuser (Novice) on Feb 10, 2018 at 05:02 UTC | |
by AnomalousMonk (Archbishop) on Feb 10, 2018 at 06:33 UTC | |
by texuser (Novice) on Feb 10, 2018 at 09:59 UTC | |
by Marshall (Canon) on Feb 10, 2018 at 18:51 UTC |