37signals/pow — pull request #248 by sstephenson (2011-11-14 19:22:39+00:00)
Title: Configuration environment refactoring

* The `Configuration` constructor's `options` argument is now an `env` argument representing a hash of environment variables, and the environment is available as a property on the instance.
* `Configuration.loadUserConfigurationEnvironment` spawns a login shell to collect the initial environment.
* Pow uses `dscl` to detect the user's shell.
* The launchd script now simply invokes the `pow` command rather than attempting to spawn `$SHELL`, which was always `/bin/bash` anyway, regardless of the user's shell setting.
* Spawned Rack applications inherit the server configuration's environment.
* The server configuration's environment is accessible via the `http://pow/env.json` endpoint for debugging purposes.