dash doesn't support pattern substitution.  revered to using tr while still
keeping things quick.