(Bug #22238) Remove EOL f17

We're removing support for Fedora 17, because it's gone End of Life.
(#15586) Use OptionParser for help

Ruby 1.9.3 dropped Rdoc.usage. The output of `facter --help` depended on
this command. The suggested change from the Rdoc maintainer is to use
the banner of the OptionParser instead. This changes it to use the
banner.
(#22233) Warn but do not fail if find gce facts without json lib

Previous patch to GCE would fail outright if there were GCE facts to
parse, but we had no JSON library.  It is better if Facter is allowed to
gather what facts it can rather than failing outright, so this change
just warns that we cannot load GCE facts due to missing JSON gem,
similar to how we warn if there is a problem parsing the GCE facts.

Also fixes up specs a little for consistency and to remove unused
references.
Merge pull request #522 from zaphod42/issue/stable/help-on-1.9.3

(#15586) Use OptionParser for help
Merge pull request #521 from melissaanne/maint/stable/re-141_rm-eol-f17

(Bug #22238) Remove EOL f17
Merge pull request #528 from jpartlow/issue/master/22233-gce-warns-but-does-not-fail-if-missing-json

(#22233) Warn but do not fail if find gce facts without json lib
(#22334) Use Facter's logging system for warn

Several points in facter would use ruby's built in warn method, which
always prints to stderr. This made unstoppable messages show up on the
stderr such as:

  [vagrant@localhost ~]$ facter virtual
  Could not retrieve virtual: Permission denied - /sys/firmware/dmi/entries/1-0/raw
  virtualbox

By using facter's normal logging system, the user has control of these
showing up and they won't end up in stderr (which might be going nowhere
in a daemonized process).
Merge pull request #529 from zaphod42/issue/stable/22334-logging-to-stderr

(#22334) Use Facter's logging system for warn
(maint) Cleanup whitespace errors
Clean up some trailing whitespace.
(#22233) Remove filters for the tests

Without this patch an example is excluded entirely if the `json` library
is not available.  If it is available then a related example is removed
instead.  This is a problem because it isn't clear why the examples are
being removed when the tests are run.

This patch addresses the problem by marking the first test as pending if
the json library is not available.  The second test always runs with
this patch applied because the patch mocks the behavior of JSON being
absent even if it is present during the test.
(#22233) Replace expect().to with .should

Without this patch we're seeing test failures on the Solaris 10 spec
system.  These failures are caused by the system not respecting the
dependencies specified in the Gemfile.  This patch addresses the problem
by changing the tests to use rspec 2.9 compatible syntax since this is a
faster route to a green build than changing the spec system itself.

This patch will be reverted once the Solaris 10 spec system has been
updated to respect the Gemfile.
Merge branch '22233_cleanup'

* 22233_cleanup:
  (#22233) Replace expect().to with .should
  (#22233) Remove filters for the tests
  (maint) Cleanup whitespace errors Clean up some trailing whitespace.
(#22349) Read from user's home when non-root

The external facts directory always assumed that the user was root, or
at least had read access to the global facts.d directory. This created
problems for users with restricted permissions when running as non-root.
Instead of trying to handle the permissions problem, which would have
made facter run, this changes facter to follow the same non-root style
as puppet, which is to look in the home directory for a .facter/facts.d
external facts directory. Simply handling the error would have had two
undesirable consequences: 1) it would have hidden a problem from the
user and 2) it would have made external facts cumbersome to use as
non-root as the user would always have to specify --external-dir, which
is not currently possible when facter is used by puppet.
Merge branch 'issue/stable/22349-facter-as-non-root' into stable

* issue/stable/22349-facter-as-non-root:
  (#22349) Read from user's home when non-root
Merge remote-tracking branch 'upstream/stable'

* upstream/stable:
  (#22349) Read from user's home when non-root
  (#22334) Use Facter's logging system for warn
  (#15586) Use OptionParser for help
  (Bug #22238) Remove EOL f17

Conflicts:
	spec/unit/ec2_spec.rb
	spec/unit/util/loader_spec.rb
Maint: Only try to install json gem for ruby 1.8

The json gem contains native code, so a compiler must be present in
order to install the gem (bundle install). On Windows, we intentionally
do not install the devkit, mainly for security reasons.

However, the json gem is only required when running ruby 1.8, so we
confine the Gemfile accordingly. This resolves the issue on Windows,
because we only support ruby 1.9 on that platform.
(#22349) Qualify WinBuiltinAdministratorsSid constant

Previously, we were getting a NameError when trying to resolve the
WinBuiltinAdministratorsSid constant, though it seems to be load order
dependent.
Merge remote-tracking branch 'upstream/stable'

* upstream/stable:
  (#22349) Qualify WinBuiltinAdministratorsSid constant
  Maint: Only try to install json gem for ruby 1.8
(packaging) Update FACTERVERSION to 1.7.3
Merge branch 'release/1.7.3' into stable

* release/1.7.3:
  (packaging) Update FACTERVERSION to 1.7.3