fix typo and call unlinkSync to clean up gen files