Split code up into library and a running app