Remove Empty Lines

Blank lines out, everything else untouched.

Blank lines out, everything else untouched.

How to use it

  1. Paste the text. Anything with gaps in it: a list, a log, a document pasted out of a PDF.
  2. Read the count. The line underneath says how many lines went, which is a quick check that it did what you expected.
  3. Copy the result. The remaining lines keep their order and their contents exactly.

When you would use this

Text copied out of a PDF, an email or a spreadsheet arrives full of gaps, and those gaps break whatever you paste it into next. Removing them is a one line job in an editor that supports regular expressions and a fiddly one everywhere else, which is why this exists. A line counts as blank if it contains nothing at all or nothing but whitespace, because a line of three spaces looks empty and behaves empty in every context you are likely to care about. Everything else is left exactly as it was, including its own leading and trailing spaces, since trimming is a different decision with its own tool. One warning worth repeating: blank lines are what separate paragraphs, so running prose through this collapses it into a single block.

Questions

Does it remove lines that look empty but have spaces?
Yes. A line containing only spaces or tabs counts as blank, because it looks blank and behaves blank in almost every context you would paste into.
Will it join my paragraphs together?
Yes, and that is worth knowing before you paste an article. Paragraph breaks are blank lines, so removing them turns prose into one block. This is a list tool rather than a document tool.
Is my list sent anywhere?
No. The work happens in the page. There is no server here, which is also why it keeps going with the network disconnected.