Re: TextEdit, delete all blank lines
Re: TextEdit, delete all blank lines
- Subject: Re: TextEdit, delete all blank lines
- From: Christopher Nebel <email@hidden>
- Date: Mon, 11 May 2009 10:54:17 -0700
On May 9, 2009, at 10:37 AM, John Masters wrote:
Anyhow, tested on the command line the following works as a shell
script:
"sed '/^ *\\$/d' filename1 > filename2"
so do shell script with the above should work. Has the advantage of
preserving the original file.
For those of you who aren't regular-expression-literate, note that the
above script doesn't do quite the same thing as the original
AppleScript script: this one deletes any line composed of zero or more
space characters -- in other words, lines that are visually empty. To
make it delete only lines that are completely empty, remove the " *"
bit.
--Chris Nebel
AppleScript Engineering
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden