Deleting (Only) First Blank Line in File

Tim Evans tkevans at fallst.UUCP
Fri Jun 29 12:40:56 AEST 1990


Can someone help me to delete the _first_ occurring blank line of a file
(whereever it occurs) without deleting subsequent ones?

You'd think the following would work, but it doesn't:

	sed 's/^$//1' foo > newfoo

Solutions other than those using 'perl' are preferred.

Thanks
-- 
UUCP:		{rutgers|ames|uunet}!mimsy!woodb!fallst!tkevans
INTERNET:	tkevans%fallst at wb3ffv.ampr.org
Tim Evans	2201 Brookhaven Ct, Fallston, MD 21047



More information about the Comp.unix.questions mailing list