More stuff
Factor out the parts of the main file