Updated to the new config API, docs fixes and more cleanup.