Remove empty lines

Uses a regular expressions to automatically get rid of new lines that don’t have any text in them.

Actions Used

shortcuts-action-icon-copy-to-clipboard.webp
Copy to Clipboard
Copies the result of the last action to the clipboard.
shortcuts-action-icon-replace-text.webp
Replace Text
Replaces some text passed into the action with other text.
shortcuts-action-icon-show-notification.webp
Show Notification
Displays a local notification.

Extra Details

Run Shortcut deep link
shortcuts://run-shortcut?name=Remove%20empty%20lines
Open Shortcut deep link
shortcuts://open-shortcut?name=Remove%20empty%20lines
AppleScript code
tell application “Shortcuts Events” run shortcut “Remove empty lines” end tell

More From This Folder

Change text case

Takes the input from the Share sheet or clipboard, lets you choose from UPPERCASE, lowercase, Capitalizing Every Word, swapping to Title Case, or swapping to Sentence case, and copies it to your clipboard.

Get Shortcut »

Spell check

Corrects the spelling of the text shared as input or from your clipboard, then presents it a prompt to confirm before copying.

Get Shortcut »

Special characters

Contains a dictionary of names and symbols that, when passed into Choose From List, becomes selectable – for whichever option is chosen, the corresponding symbol will be passed out and copied to the clipboard.

Get Shortcut »

More From The Library

Toggle listening history

Asks you to pick a focus mode, then toggles the current Music Focus Filter setting for “Use Listening History” so you can switch whether or not to Use Listening History for a chosen focus with an existing filter. Works well as a Control in Control Center.

Get Shortcut »


Get way deeper into Shortcuts – become a member.