Fix some things as per @adrienthebo's comments:

  * Put Facter::Util::Resolution.exec inside setcode block when
    possible
  * Use true/nil instead of yes/no
  * Use each_with_index
  * Move doc before each fact declaration