>  if I remove unset(PLANTUML CACHE) "cmake ." doesn't detect when a user remove plantuml script and rerun "cmake ."

True, but that's hardly a common occurrence (and the user can always uncache it himself, if need be). I think the benefits of caching in this case outweigh the drawbacks, plus it's consistent with all the other finders, so I would still suggest to remove the `unset`.