reorganise repo structure and add a build system