Simplified sed for portability