[c-nsp] eem-script problem

Peter Rathlev peter at rathlev.dk
Fri Jan 4 08:22:29 EST 2019


On Fri, 2019-01-04 at 00:34 +0100, Peter Rathlev wrote:
> When testing on IOS 15.2 it seems that the regular expression has an
> implicit anchor in the beginning ("^"). If you don't mind the extra
> whitespace in front of the result then a short version is:
> 
>   action 1.02 regexp ".+CRC" $_cli_result var
>   action 1.03 puts "match is $var"

Sorry, I must have been sleepy. There is no implicit start anchor, I
just mistyped when testing. Without whitespace, not using a submatch:

 action 1.02 regexp "[^ ].+CRC" $_cli_result var

-- 
Peter



More information about the cisco-nsp mailing list