Add support for working-dir global option

You cannot re-assign a variable like this in Puppet (which is evident of the test failures). Can you modify this to something like `$wdir = $working_dir ? {` and push a new or amended commit?