Steps in creating a new Colab Jupyter Notebook and saving to a repository in Github
- create github repository (example: "Google-Colab-Notebooks")
Creating a new Colab Notebook and saving in Github
- Create a new Google Colab notebook
- go to Colab and click on New Notebook (choose either Python 2 or 3.6)
- By default this notebook file is created in your Google Drive under Colab Notebooks
- Add contents/edit/run notebook
- Click on File/Save a copy in GitHub, you'll be asked to login to your GitHub account and authroize app once.
- Each time you save, you can add a commit message for github.
- After saving to GitHub, you will get a link “View in Colaboratory” which opens your notebook directly in Colab
Copying existing publicly shared Notebook and saving in Github
- you can download an existing notebook manual and save and open as a Colab notebook in your google drive
- or you can clone the Github Repository to Google Colab
- you can also copy an existing publicy shared Colab notebook
- Add contents/edit/run notebook
- Click on File/Save a copy in GitHub, you'll be asked to login to your GitHub account and authroize app once.
- Each time you save, you can add a commit message for github.
- After saving to GitHub, you will get a link “View in Colaboratory” which opens your notebook directly in Colab