Fixed problem with expand variable into sed