Nahrazeni sekvence znaku

Opty opty77 na gmail.com
Sobota Říjen 28 20:46:02 CEST 2006


On 10/26/06, linux na edoras.cz <linux na edoras.cz> wrote:
> Dobry den

I vam...

> Druhy napad byl pouzit sed. Neco jako sed 's/jedna/\n/' .
> Jenze nastal druhy problem, jelikoz sed nahradi pouze prvni vyskyt
> retezce na radku a nasledujici vyskyty daneho retezce na radku jiz ignoruje.
>
> Poradil by nekdo prosim?

info sed

The "s" Command

The syntax of the `s' (as in substitute) command is
`s/REGEXP/REPLACEMENT/FLAGS'.

The `s' command can be followed by zero or more of the following FLAGS:

`g'
     Apply the replacement to _all_ matches to the REGEXP, not just the first.

Hezky den,
Opty


Další informace o konferenci Linux