Remove empty lines in VI using SED

Solved
pcsystemd Posted messages 734 Status Membre -  
 Yeah -
Hello,

I can’t remember the command to delete empty lines with sed in VI. I tried the following code, but it doesn’t work.

s/^$/d


Do you have any ideas?

Thank you
--
Access to knowledge is the first freedom that every person should have.
Configuration: Linux Mozilla 1.9.0.4

2 réponses

jipicy Posted messages 40842 Registration date   Status Modérateur Last intervention   4 898
 
Hi,
:g/^$/d
;-))

--
$ man woman
There is no manual page for woman.
21
Yeah
 
Ty
0
pcsystemd Posted messages 734 Status Membre 23
 
Thank you very much jipicy.

--
Access to knowledge is the first freedom that every man should have.
1