Replaced gsed with bsd sed line