TextSoap extension for specific cleaner function?

Greetings

Is it possible to create a TextSoap extension which does not go to the menu of TextSoap cleaners but instead activates a specific cleaner?

1 Like

I think so indeed, something like:

#popclip
name: TextSoap Single Action
title: ts
after: paste-result
applescript: |
  tell application "textsoapAgent"
    return cleanText "{popclip text}" with "Remove Extra Spaces"
  end tell

EDIT: Doesn’t work … not sure why yet…
EDIT2: Oops, forgot the |. Works now.

3 Likes

Perfect - thank you @nick

That is really useful particularly given how many TextSoap cleaners exist and especially how easy TextSoap makes it to create a custom cleaner.

PopCip and TextSoap are truly greater than the individual parts when used together. You might want to each do a bit of soft advertising for the other on your websites.

@rkaplan — I haven’t tried making a custom cleaner for TextSoap. Is there a dead simple tutorial I could follow somewhere?

@macfixer

No coding needed at all so yes it is dead simple. Just choose “Customize” for your category of cleaners and it has a whole bunch of options for you to choose from.

If you get a bit more advanced, you can assemble these as block into a “Macro” via their GUI.

Beyond that you can use a MacOS Automator action as part of a TextSoap cleaner.

If you are familiar with Regular Expressions to some extent (lots of tutorials available on the web) I think the implementation in TextSoap is a bit easier than some of the other methods to do that with PopClip.