Refactoring _get_environment.

- Removes use of "global" by putting the env name in another
  namespace.
- Splits logic into digestible pieces.
- Also makes slight change to GoogleCredentials docstring.
Using settings namedtuple instead of client_settings module.
Merge pull request #83 from dhermes/refactor-env-name

Refactoring _get_environment.