Format code, minor cleanup, add .settings/ to .gitignore