 |
 |
Remove blank lines from a text file?
|
 |
|
 |
|
Dedicated MacNNer
Join Date: Apr 2003
Location: Detroit, MI
Status:
Offline
|
|
I have a document that has extra blank lines a plenty. Any easy way to remove them? I have TextEdit, Word, and Pages but have not found a way to do it. Maybe an Apple script?
Thanks!
|
|
|
| |
|
|
|
 |
|
 |
|
Mac Enthusiast
Join Date: Nov 2003
Location: great northwest
Status:
Offline
|
|
There's a Service called Format that I think I got from Devon . Go there and download WordServices, which offers lots of cleanup possibilities, including removing blank lines. there's some other useful freeware at that site. I use them all the time.
There's also a Service called SmartWrap, and apps called PlainClip and TextSoap that clean up text.
|
|
|
| |
|
|
|
 |
|
 |
|
Addicted to MacNN
Join Date: Oct 2001
Location: Yokohama, Japan
Status:
Offline
|
|
What format is the file? If it's just plain text, a simple Terminal command can do that.
Code:
sed -e '/^$/d' your-file-here.txt > output-file.txt
(Last edited by wataru; Apr 10, 2005 at 04:25 AM.
)
|
|
|
| |
|
|
|
 |
|
 |
|
Addicted to MacNN
Join Date: Jun 1999
Location: Las Vegas, NV, USA
Status:
Offline
|
|
In Word, replace ^p^p with ^p
Chris
|
|
|
| |
|
|
|
 |
|
 |
|
Dedicated MacNNer
Join Date: Apr 2003
Location: Detroit, MI
Status:
Offline
|
|
Thank you all! I appreciate everyone who took the time to answer.
|
|
|
| |
|
|
|
 |
 |
|
 |
|
|
|
|
|

|
|
 |
Forum Rules
|
 |
 |
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is Off
|
|
|
|
|
|
 |
 |
 |
 |
|
 |