Search and Replace for \n

Well done on the release version of DTTG 4. I appreciate the pricing model that is connected with my DT Pro subscription.

Question: How do I perform a “search and replace” for extra newline (\n) or end of paragraph markers in DT and DTTG?

I would like to be able to search for \n\n\n and replace them with \n\n, which is easy in BBEdit but I am stumped on how to accomplish this directly in DT.

Yours,

Mark

In DT, you can use a script. In DTTG, I have no idea.

BBEdit isn’t a typical application but is a bespoke text editing application with many specialized tools so it’s not a good direct comparison. For example, see TextEdit (which also uses the same text engine as DEVONthink).

Option-Return can be used in DEVONthink but not UNIX-y \n.

DTTG doesn’t currently support this, however in DT4 you can enter ⌥ + Return in the search inspector text fields.

2 Likes

Thanks so much. I recognize that BBEdit is a much more complex program. I have set up DT so that I can open documents in BBEdit, but I wanted to replicate this aforementioned search and replace function inside the native DT markdown editor. I appreciate the quick response.

You’re welcome. The Option-Return trick works in many native macOS apps. I’ve been using it for two decades :slight_smile: