hi tnx but that's not what I am looking for.
like I said I dont want to specify then pattern for
sed.
I want it automatically find all the patterns that are repeated and do something with them. the regular expression would be something like this:
'.*\{3,\}\.*\1'
but I can only save the whole thing into register1, I cant distinguish between the first pattern, repeated pattern and possible contents between them.