Ralph Shumaker wrote:

Examples:
   ^2And ...
   ^3This ...
   ^4And ...
   ^5Before ...
   ^6Like ...
   ^7He ...
   ^8Open ...
   ^9And ...
   ^10 For ...
   ^11 Certain ...
   ^2Because ...
   ^3Open ...
   ^4Begin ...
   .
   .
   .

Needed to be:
   ^2 And ...
   ^3 This ...
   ^4 And ...
   ^5 Before ...
   ^6 Like ...
   ^7 He ...
   ^8 Open ...
   ^9 And ...
   ^10 For ...
   ^11 Certain ...
   ^2 Because ...
   ^3 Open ...
   ^4 Begin ...

Okay, given that, couldn't you have used:

\^\d+\s+\w+

\^ escapes the caret
\d+ matches one or more digits [0-9]
\s+ matches one or more whitespace
\w+ matches one or more word characters [0-9A-Za-z_]


Although, you would still have to handle grouping the match for the replace.

-a


--
[email protected]
http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-list

Reply via email to