Importing repo from public to private network

Hi
Is there a way to import a public repository with all of its dependencies to a private network? I didn’t find supporting commands for that. Any thoughts on that?