shell-script-pt
[Top][All Lists]
Advanced

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

Re: [shell-script] sed - inserir linha


From: Jorge Nickolas Zaven Dias da Silva
Subject: Re: [shell-script] sed - inserir linha
Date: Mon, 26 Jul 2004 09:22:29 -0300
User-agent: Internet Messaging Program (IMP) 3.2.4

Apenas complementando a pergunta.
Quero inserir uma linha "teste = 5" na linha seguinte que encontrar "teste = 4",
como uma nova linha!?
Alguma ajuda.
Um abraço.

Nickolas.

Citando Aurelio Marinho Jargas <address@hidden>:

> oi celso,
>
> --- Celso Vianna <address@hidden> escreveu:
> > executando o comando sed '15i meu texto' rc.conf - me foi
> > retornado o seguinte:
> > sed: 1: "1i foda": command i expects \ followed by text
>
> faz assim ó:
>
> $ seq 5 | sed -e '3i\' -e 'texto extra'
> 1
> 2
> texto extra
> 3
> 4
> 5
>
> falou!
>
> =====
> --
> Aurelio Marinho Jargas, Curitiba, Conectiva
> hype: txt2tags v2.0 FINAL em 25 de Julho
> http://aurelio.net
>
>
>
>
>
> _______________________________________________________
> Yahoo! Mail agora com 100MB, anti-spam e antivírus grátis!
> http://br.info.mail.yahoo.com/
>


--


----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]