various updates needed to sanatize env for sed