Proper Main and other stuff