Page 1 of 1

Add fullstop to end of line

Posted: Fri Jan 01, 2010 7:06 pm
by jboydell
Can anyone explain how I can add a fullstop to the end of a line if one does not already exist? I have tried using EasyPattern search and replace but I just don't get the results I expect. Any blank lines should not have have a fullstop added.

Re: Add fullstop to end of line

Posted: Fri Jan 08, 2010 9:42 am
by DataMystic Support
Use a Filters\Restrict\Non-matching lines (inverse grep), with a perl pattern of
\.

This will match all lines without a full stop (period).

Then INSIDE this filter, add a subfilter with a Filters\Add\Right margin filter.

Re: Add fullstop to end of line

Posted: Sun Jan 10, 2010 1:50 am
by jboydell
Thanks, I am most of the way there by following your suggestion, however, even blank lines get a fullstop at the end (which I don't want). Is there a way to avoid this?

Re: Add fullstop to end of line

Posted: Sun Jan 10, 2010 1:05 pm
by DataMystic Support
Yes, inside the Non-matching lines filter, add a subfilter that matches the perl pattern:
.
and add the right margin filter inside this.