$ cat TAG MYTAG ( Line 1 Line 2 Line 3 ); NOTMYTAG ( foo bat ); MYTAG ( Line 1 Line 2 Line 3 ); $ perl -n -e 'BEGIN{$com=""}' -e '$com="#"if/^MYTAG\W/;print"$com$_";$ +com=""if/^\);$/' <TAG #MYTAG ( #Line 1 #Line 2 #Line 3 #); NOTMYTAG ( foo bat ); #MYTAG ( #Line 1 #Line 2 #Line 3 #);
In reply to Re: How to comment out lines in a text?
by zengargoyle
in thread How to comment out lines in a text?
by ginju75
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |