It works! Also, much tidier. Thanks Rich for that, and to everyone else for 
all the hand holding. I can't thank you enough.

On Wednesday, May 26, 2021 at 7:12:21 AM UTC-6 sie...@barebones.com wrote:

> On 26 May 2021, at 0:19, Duncan Thorne wrote:
>
> > You are all a helpful bunch but I'm still sinking! I looked at the 
> > manual
> > and it addles my brain. Grep, zero-width positions, etc. Yikes.
>
> I think you'll find it simpler if you eliminate Grep from the process 
> and do a literal search. Try writing the "replace" operation in your 
> script as follows:
>
> replace "2021\\n$" using "2021\\t$" options {search mode:literal, case 
> sensitive:false, starting at top:true}
>
> ("\n" and "\t" are backslash character escapes for line break and tab, 
> respectively. The AppleScript editor will compile these into literal 
> characters, so to avoid this we add an extra backslash. If you don't do 
> that, the operation will still work, but the script is a little harder 
> to read.)
>
> R.
>
> -- 
> Rich Siegel Bare Bones Software, Inc.
> <sie...@barebones.com> <https://www.barebones.com/>
>
> Someday I'll look back on all this and laugh... until they sedate me.
>

-- 
This is the BBEdit Talk public discussion group. If you have a feature request 
or need technical support, please email "supp...@barebones.com" rather than 
posting here. Follow @bbedit on Twitter: <https://twitter.com/bbedit>
--- 
You received this message because you are subscribed to the Google Groups 
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to bbedit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/bbedit/8249aeb1-5193-447a-896e-75997ded75d9n%40googlegroups.com.

Reply via email to