puppetlabs/puppet — pull request #2334 by jpartlow (2014-02-07 00:01:26+00:00)
Title: (PUP-1574) Environment setting does not override apply/parser manifest

Both `puppet apply` and `puppet parser validate` were relying on the
legacy environment behavior to implicit draw in the setting of
Puppet[:manifest]. But the new directory environments do not pay
attention to Puppet[:manifest] and thus a call such as `puppet apply
foo.pp --environment dir_env` would not apply foo.pp if dir_env was in
the $environmentpath.

This change explicitly creates a new environment based off the currently
configured environment and overrides with the manifest this to be
applied or validated.