Is there a way to tell
sed to replace the pattern on every second occurrence? Or at least on every second line? (Sure it's possible with a script, but I was asking myself if
sed can do it to).
sed -e "s/pattern/replacement/g;n"
But it replaced every first occurence, not the second.