Merge settings and allow local settings.

Fixes #11. Fixes #32.