Methods for using Git with Google Colab

前端 未结 12 794
臣服心动
臣服心动 2020-12-12 11:42

Are there any recommended methods to integrate git with colab?

For example, is it possible to work off code from google source repositories or the likes?

Nei

12条回答
  •  無奈伤痛
    2020-12-12 12:05

    git is installed on the machine, and you can use ! to invoke shell commands.

    For example, to clone a git repository:

    !git clone https://github.com/fastai/courses.git
    

    Here's a complete example that clones a repository and loads an Excel file stored therein. https://colab.research.google.com/notebook#fileId=1v-yZk-W4YXOxLTLi7bekDw2ZWZXWW216

提交回复
热议问题