remove unneeded lines from the lockfile