That seemed like magic to me at first too. I think though that is happens during the installation of the package, which is why he had to reinstall after refactoring.
I initially just skimmed over his log dump from the install, but I think the details are actually important there:
> writing entry points to cute_snek.egg-info\entry_points.txt