Re: Simple join of 2 lines!!! Arrgh!
From: Carlos J. G. Duarte (cjgd_at_clix.pt)
Date: 01/30/04
- Next message: Ed Morton: "Re: for loop (?)"
- Previous message: Stein Arne Storslett: "Re: Simple join of 2 lines!!! Arrgh!"
- In reply to: Shaun: "Simple join of 2 lines!!! Arrgh!"
- Next in thread: Shaun: "Re: Simple join of 2 lines!!! Arrgh!"
- Reply: Shaun: "Re: Simple join of 2 lines!!! Arrgh!"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Fri, 30 Jan 2004 12:53:18 +0000
Shaun wrote:
> so I thought I'd just replace EOLXXXX (+newline) with nothing, i.e. delete it thus:
>
> tr -d 'EOLXXXX\012' <file1 >file2
>
> but for some reason this removes all newline characters?
tr -d 'character set' will remove these characteres from input.
This is best done with sed:
$ sed 's/EOLXXX.*$//; N; s/\n/ /'
-- carlos ** http://cgd.sdf-eu.org
- Next message: Ed Morton: "Re: for loop (?)"
- Previous message: Stein Arne Storslett: "Re: Simple join of 2 lines!!! Arrgh!"
- In reply to: Shaun: "Simple join of 2 lines!!! Arrgh!"
- Next in thread: Shaun: "Re: Simple join of 2 lines!!! Arrgh!"
- Reply: Shaun: "Re: Simple join of 2 lines!!! Arrgh!"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|