1

How do you pip install from a private repo via Google Cloud Source repos? Seems like something that should be possible.

!pip install gcloud source repos clone [REPOSITORY_NAME] --project=[PROJECT_NAME]
TimK
  • 819
  • 1
  • 10
  • 22

1 Answers1

2

I haven't used Cloud Source Repositories (so I haven't tested this), but it seems like you would need to do one of two things:

  1. pip install from the repo's URL, if it has a public URL. For example, something like the following:
!pip install https://source.developers.google.com/p/[PROJECT_ID]/r/[REPO_NAME]
  1. pip install from a local clone of your repository. For example:
gcloud source repos clone [REPOSITORY_NAME] --project=[PROJECT_NAME] 
!pip install -e [PATH_TO_CLONED_REPO]
Alireza Rezaee
  • 314
  • 3
  • 10
joe.liedtke
  • 582
  • 2
  • 14