How would I replace the first 150 characters of every line with spaces using sed. I don't want to bring out the big guns (Python, Perl, etc) and it seems like sed is pretty powerful in itself (some people have written the dc calculator in it for example). A related problem is inserting 150 spaces in front of every line.
s/^.\{50\}/?????/
That matches the first 50 characters but then what? I can't do output
s/^.\{50\}/ \{50\}/
One could use readline to simulate 150 presses (alt+150, ) but that's lame.