awesome: clean up string formatting function