fixed sed and added #exec output. thanks to SirFinkus for the heads up