Almost finished with our AutoKey Script Migration. Got this one which is stumping me.
Need to take the contents of the clipboard, and remove multiple blank lines so they are replaced by a single blank line.
eg this
"Big Rig" - When an old pal of Torres' comes to him - disheveled and bloodied - for guidance amidst an undercover FBI operation and then disappears, NCIS helps track him down. Also, McGee prepares to be a contestant on a popular game show, on the CBS Original series NCIS, Monday, Jan. 23 (9:00-10:00 PM, ET/PT) on the CBS Television Network and available to stream live and on demand on Paramount+*.
REGULAR CAST:
Sean Murray (NCIS Special Agent Timothy McGee)
Wilmer Valderrama (NCIS Special Agent Nicholas "Nick" Torres)
Brian Dietzen (Medical Examiner Jimmy Palmer)
Diona Reasonover (Forensic Scientist Kasie Hines)
Katrina Law (NCIS Special Agent Jessica Knight)
Rocky Carroll (NCIS Director Leon Vance)
Gary Cole (FBI Special Agent Alden Parker)
Last Line
Would be come this
"Big Rig" - When an old pal of Torres' comes to him - disheveled and bloodied - for guidance amidst an undercover FBI operation and then disappears, NCIS helps track him down. Also, McGee prepares to be a contestant on a popular game show, on the CBS Original series NCIS, Monday, Jan. 23 (9:00-10:00 PM, ET/PT) on the CBS Television Network and available to stream live and on demand on Paramount+*.
REGULAR CAST:
Sean Murray (NCIS Special Agent Timothy McGee)
Wilmer Valderrama (NCIS Special Agent Nicholas "Nick" Torres)
Brian Dietzen (Medical Examiner Jimmy Palmer)
Diona Reasonover (Forensic Scientist Kasie Hines)
Katrina Law (NCIS Special Agent Jessica Knight)
Rocky Carroll (NCIS Director Leon Vance)
Gary Cole (FBI Special Agent Alden Parker)
Last Line
I tried this
{text={clipboard}}
{=replaceregex(text, "\n{3,}", "\n\n", "sg")}
Which I though would replace multiple new lines with a single but it does not seem to remove them.