Better sed command and removed git checkout refresh step.