Re: need help: about remove space

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



Am 30.04.2010 16:46, schrieb adrian kok:

> I have big file as below 
> and would like to know how many line eg: wc -l file
> but can't figure out how to know
> 
> If I type wc -l file, I only get the 1023 but it includes the space 
> When I use cat file | tr -d "\r \n". it gives me "adrian alice......"
> I need it as fileB and then wc -l fileB.

grep -cv ^$ file

> 
> Thank you so much
> 
> file
> ====
> 
> adrian
> 
> alice
> 
> 
> Patrick
> 
> 
> 
> file B
> ======
> 
> adrian
> alice
> Patrick 

Regards,

	Peter

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos

[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux