in reply to Re: Simple Text Manipulation
in thread Simple Text Manipulation
Here's the script; I added : because the word "Article" which always begins the line, is followed immediately by a colon. Using the syntax, "$ perl script.pl test.tex -w" I'm returned to the command line and the file was not processed.
#!/usr/bin/perl
s/^(Article\s+{0-9}+{:}+\s+{\w\s}+$)/\\subsection*{$1}/;
(I've replaced brackets [] with braces {} since they don't seem to show up here.
In Section
Seekers of Perl Wisdom