On Tue, Oct 01, 2002 at 11:27:17AM +1000, Simon Wong wrote: : I want to comment out every line in a file (inetd.conf) but not the ones : that already are. : : I tried : : :1,$s/^/# : : which does every line. Looks very uncool.
Try :v/^#/s/^/#/ or :g/^[^#]/s/^/#/ They should have slightly different behaviours. -- Christopher Vance -- SLUG - Sydney Linux User's Group - http://slug.org.au/ More Info: http://lists.slug.org.au/listinfo/slug