Implemented keep option to allow temp file removal