Change echo commands to printf