Added cleanup of nupic.core submodule after build.

The build leaves nupic.core submodule in an altered state because of the
files it dumps. This resets all submodules to initial state after
building.
Using secure URL for submodule
Cleanup build script re: submodule.

Trying to plan for different states. If a user removes the nta dir
submodule, this will put it back before initializing the submodule. Also
cleans up after build in a cleanup function.