RE: Unix question - correction

  • From: <k.sriramkumar@xxxxxxxxxxxxxxxxxx>
  • To: <oracle-l@xxxxxxxxxxxxx>
  • Date: Mon, 10 May 2004 13:47:44 +0530

Hi,
 
Use this command 
 
:g/^ *$/d
 
This shud delete all the lines having spaces.
 
Best Regards
 
Sriram Kumar
 
 

        -----Original Message----- 
        From: oracle-l-bounce@xxxxxxxxxxxxx on behalf of 
manoj.gurnani@xxxxxxxxxxxxx 
        Sent: Mon 5/10/2004 12:42 PM 
        To: oracle-l@xxxxxxxxxxxxx 
        Cc: 
        Subject: RE: Unix question - correction
        
        

        Hi,
           I found that the lines in my file were not blank.
        But there were leading spaces before the end of line causing the
        continuation to the next line.
        How can I remove leading spaces before the end of line in the file.
        Thanks
        Manoj
        
        
        -----Original Message-----
        From: oracle-l-bounce@xxxxxxxxxxxxx 
[mailto:oracle-l-bounce@xxxxxxxxxxxxx]
        On Behalf Of Richard Ji
        Sent: Friday, May 07, 2004 11:25 PM
        To: oracle-l@xxxxxxxxxxxxx
        Subject: RE: Unix question - correction
        
        
        Oops, forgot the dollar sign
        :g/^[ \t]*$/d
        
        
        -----Original Message-----
        From:   Richard Ji
        Sent:   Fri 5/7/2004 1:48 PM
        To:     oracle-l@xxxxxxxxxxxxx
        Cc:    
        Subject:        RE: Unix question
        in vi do:
        :g/^[ \t]*/d
        
        Note the space character
        
        -----Original Message-----
        From:   srinivasan v [mailto:srini@xxxxxxxxxxxxxx]
        Sent:   Fri 5/7/2004 6:14 AM
        To:     oracle-l@xxxxxxxxxxxxx
        Cc:    
        Subject:        RE: Unix question
        Manoj,
        sed would do it. Any reason why you want to do it in  "vi" alone ? Try
        this sed '/^$/ d' file > file_without_blanks
        
        HTH
        
        srini
        
        -----Original Message-----
        From: oracle-l-bounce@xxxxxxxxxxxxx
        [mailto:oracle-l-bounce@xxxxxxxxxxxxx]On Behalf Of
        manoj.gurnani@xxxxxxxxxxxxx
        Sent: Friday, May 07, 2004 5:56 PM
        To: oracle-l@xxxxxxxxxxxxx
        Subject: Unix question
        Importance: High
        
        
        Hi,
           I want to remove all blank lines in a file using vi editor. Which
        command can do the needful. Thanks Manoj
        
        -- Attached file included as plaintext by Ecartis --
        -- File: InterScan_Disclaimer.txt
        
        This e-Mail may contain proprietary and confidential information and is
        sent for the intended recipient(s) only. If by an addressing or
        transmission error this mail has been misdirected to you, you are
        requested to delete this mail immediately. You are also hereby notified
        that any use, any form of reproduction, dissemination, copying,
        disclosure, modification, distribution and/or publication of this e-mail
        message, contents or its attachment other than by its intended 
recipient/s
        is strictly prohibited.
        
        Visit Us at http://www.polaris.co.in
        
        
        ----------------------------------------------------------------
        Please see the official ORACLE-L FAQ: http://www.orafaq.com
        ----------------------------------------------------------------
        To unsubscribe send email to:  oracle-l-request@xxxxxxxxxxxxx put
        'unsubscribe' in the subject line.
        --
        Archives are at //www.freelists.org/archives/oracle-l/
        FAQ is at //www.freelists.org/help/fom-serve/cache/1.html
        -----------------------------------------------------------------
        
        ----------------------------------------------------------------
        Please see the official ORACLE-L FAQ: http://www.orafaq.com
        ----------------------------------------------------------------
        To unsubscribe send email to:  oracle-l-request@xxxxxxxxxxxxx put
        'unsubscribe' in the subject line.
        --
        Archives are at //www.freelists.org/archives/oracle-l/
        FAQ is at //www.freelists.org/help/fom-serve/cache/1.html
        -----------------------------------------------------------------
        
        
        
        
        -- Binary/unsupported file stripped by Ecartis --
        -- Type: application/ms-tnef
        -- File: winmail.dat
        
        
        ----------------------------------------------------------------
        Please see the official ORACLE-L FAQ: http://www.orafaq.com
        ----------------------------------------------------------------
        To unsubscribe send email to:  oracle-l-request@xxxxxxxxxxxxx put
        'unsubscribe' in the subject line.
        --
        Archives are at //www.freelists.org/archives/oracle-l/
        FAQ is at //www.freelists.org/help/fom-serve/cache/1.html
        -----------------------------------------------------------------
        
        
        
        
        -- Binary/unsupported file stripped by Ecartis --
        -- Type: application/ms-tnef
        -- File: winmail.dat
        
        
        ----------------------------------------------------------------
        Please see the official ORACLE-L FAQ: http://www.orafaq.com
        ----------------------------------------------------------------
        To unsubscribe send email to:  oracle-l-request@xxxxxxxxxxxxx put
        'unsubscribe' in the subject line.
        --
        Archives are at //www.freelists.org/archives/oracle-l/
        FAQ is at //www.freelists.org/help/fom-serve/cache/1.html
        -----------------------------------------------------------------
        
        -- Attached file included as plaintext by Ecartis --
        -- File: InterScan_Disclaimer.txt
        
        This e-Mail may contain proprietary and confidential information and is 
sent for the intended recipient(s) only.
        If by an addressing or transmission error this mail has been 
misdirected to you, you are requested to delete this mail immediately.
        You are also hereby notified that any use, any form of reproduction, 
dissemination, copying, disclosure, modification,
        distribution and/or publication of this e-mail message, contents or its 
attachment other than by its intended recipient/s is strictly prohibited.
        
        Visit Us at http://www.polaris.co.in
        
        
        
        ----------------------------------------------------------------
        Please see the official ORACLE-L FAQ: http://www.orafaq.com
        ----------------------------------------------------------------
        To unsubscribe send email to:  oracle-l-request@xxxxxxxxxxxxx
        put 'unsubscribe' in the subject line.
        --
        Archives are at //www.freelists.org/archives/oracle-l/
        FAQ is at //www.freelists.org/help/fom-serve/cache/1.html
        -----------------------------------------------------------------
        

-- Binary/unsupported file stripped by Ecartis --
-- Type: application/ms-tnef
-- File: winmail.dat


----------------------------------------------------------------
Please see the official ORACLE-L FAQ: http://www.orafaq.com
----------------------------------------------------------------
To unsubscribe send email to:  oracle-l-request@xxxxxxxxxxxxx
put 'unsubscribe' in the subject line.
--
Archives are at //www.freelists.org/archives/oracle-l/
FAQ is at //www.freelists.org/help/fom-serve/cache/1.html
-----------------------------------------------------------------

Other related posts: