I have a regex in my perl script which is /Operating System:\s*(.*)/
.
The line I am matching is Operating System: Windows XP Service Pack 3
however, there is a new line after entered after that line. So the text would be seen as Operating System: Windows XP Service Pack 3^M
.
Is there anyway to get rid of the ^M
using the current regex I have? It captures Windows XP Service Pack 3^M
but the ^M
doesn't display only when I display the content using command prompt or PuTTy's more
. It displays when I edit using vi
or rather vim
.
Any help on this?
You can try this.