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

Re: [Pour être précis] Re: grep ou awk



Le 2001.12.08 11:49, LUTHIER Olivier a écrit :
> ok,
> 
> sauf que dans ce cas là on travail sur un fichier ayant une ligne unique.
> Ainsi, quand je test ta commande, c'est donc toute la ligne qu'il
> m'affiche
> !
> 

Ca marche de la même manière avec un fichier. Par contre j'ai peur que la
longueur de la ligne pose des problèmes même si GNU sed n'a pas de limite.

un extrait du 'info sed'

About the (non-)limitations on line length
******************************************

   For those who want to write portable SED scripts, be aware that some
implementations have been known to limit line lengths (for the pattern
and hold spaces) to be no more than 4000 bytes.  The POSIX.2 standard
specifies that conforming SED implementations shall support at least
8192 byte line lengths.  GNU SED has no built-in limit on line length;
as long as SED can malloc() more (virtual) memory, it will allow lines
as long as you care to feed it (or construct within it).



Reply to: