removed crazy line endings; simplified crazy greps