Clean copied text with a double tap
Text copied from a PDF, an email or a website pastes with lines broken in odd places and double spaces. Copy it, tap the back of your iPhone twice, and paste it clean.
Build the shortcut
- Open Shortcuts, tap +, and name it
Clean clipboard. - Add Get Clipboard.
- Add Replace Text. Find
\s*\n\s*, replace with a single space, and turn on Regular Expression. This joins the broken lines. - Add Replace Text again. Find
{2,}(a space followed by{2,}), replace with a single space, Regular Expression on. This removes double spaces. - Add Copy to Clipboard.
- Add Show Notification with the text
Clipboard cleaned.
Run it with a double tap on the back of the phone
- Open Settings, then Accessibility, then Touch, then Back Tap.
- Choose Double Tap and pick
Clean clipboardfrom the shortcuts list.
Now: copy, double tap the back of the phone, paste.
Why it helps
No more fixing line breaks by hand before sending a quote, an address or a paragraph on.