Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 15 Nov 2006 15:21:53 +0000
From:      Vince <jhary@unsane.co.uk>
To:        Jack Stone <antennex@hotmail.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Another FBSD utility/script question
Message-ID:  <455B3091.2050903@unsane.co.uk>
In-Reply-To: <BAY125-F286DA27532386320B32DBECCEA0@phx.gbl>
References:  <BAY125-F286DA27532386320B32DBECCEA0@phx.gbl>

next in thread | previous in thread | raw e-mail | index | archive | help
Hmm
sed -e "/^$/d" FILENAME > newfilename
will do the job if they are empty lines.


Vince


Jack Stone wrote:
> Here I come with another easy one for most on the list -- except for me.
> 
> I have 12,000 plus lines that have an empty line in between each real
> line, like so:
> 
> this is a line of info 1
> (empty)
> this is a line of info 2
> 
> this is a line of info 3
> 
> etc, etc
> 
> To eliminate each "empty" line in between the "info" lines would take a
> long, long time.
> Thus my question: what tool is available or syntax to remove the 6000
> empty lines so there's no space in between?
> 
> This has got to be an easy one, except when one doesn't know the answer.
> 
> Thanks,
> 
> Jack of all trades, master of only some!
> 
> _________________________________________________________________
> Stay in touch with old friends and meet new ones with Windows Live
> Spaces
> http://clk.atdmt.com/MSN/go/msnnkwsp0070000001msn/direct/01/?href=http://spaces.live.com/spacesapi.aspx?wx_action=create&wx_url=/friends.aspx&mkt=en-us
> 
> 
> _______________________________________________
> freebsd-questions@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
> "freebsd-questions-unsubscribe@freebsd.org"




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?455B3091.2050903>