cleanup main file