refactor `brew cask doctor`

Output remains the same (except in the case of error).
Wrap all calculations in begin blocks for safety, provide fallback
values for all variables, don't use ohai+puts when ohai is
sufficient