Use lenses, some cleanup
Fix build
Fix main