fix degenerate case of find_unused_uid

Bear with me; I'm still trying to figure out Ruby.
add `doctor` command, document commands