This document will give an introduction about Git and show how to fork a GitHub repository and import it into Google Colaboratory
Version Control Systems are systems that record changes to a file or set of files over time so that you can recall specific versions later. They also help to merge the contributions of multiple people working on the same file, simplifying collaborations.
https://mambelli.github.io/git-novice/01-basics.html
Git is a distributed version-control system for tracking changes in source code during software development. It is designed for coordinating work among programmers, but it can be used to track changes in any set of files. Its goals include speed, data integrity, and support for distributed non-linear workflows. Every Git directory on every computer is a full-fledged repository with complete history and full version-tracking abilities, independent of network access or a central server. Git thinks about its data like a stream of snapshots: each time you do a commit takes a new snapshot.
https://git-scm.com/book/en/v2/Getting-Started-About-Version-Control
https://git-scm.com/book/en/v2/Getting-Started-What-is-Git%3F
GitHub is a Website and a company that provides hosting for software development version control using Git.
Here is a link to create an account on GitHub: https://github.com/join
And here a first tutorial: https://guides.github.com/activities/hello-world/
Instructions on how to make a copy of an existing repository (fork): https://help.github.com/en/articles/fork-a-repo
Alternatively, you can find the same information in the Git tutorial mentioned at the beginning: it includes chapters on how to use GitHub and how to fork a repository and collaborate with Pull Requests.
Now fork the Lesson 1 repository: https://github.com/mambelli/target-python-lesson1
To open in Google Colaboratory a Jupyter Notebook stored on GitHub, you can download it and upload it to Colab.
Alternatively, you can use the Colab API to open the notebook from GitHub, which is more direct and recommended.
Open your Notebook file on GitHub in any browser (So the URL ends in .ipynb, e.g https://github.com/mambelli/target-python-lesson1/blob/master/target_python_challenge1.ipynb).
Change the URL from https://github.com/full_path_to_your_notebook to https://colab.research.google.com/github/full_path_to_your_notebook (e.g. https://colab.research.google.com/github/mambelli/target-python-lesson1/blob/master/target_python_lesson1.ipynb). Replace only the part in bold red with the one in bold blue, the rest should be the URL of your repository or file.
Finally, click enter. And that should work and load the Notebook.
The Git introduction by Software Carpentry. Will introduce Git and how to use it via the command line. This will allow you to edit files on your computer, have a local repository, and sync it with GitHub or other remote repositories:
https://mambelli.github.io/git-novice/
GitHub can be also a great place to show off your programming skills, here are some suggestions.
And this is a playful way to learn about Git branching and operations.
Jupyter notebooks can be tricky to compare because changes in the output or metadata may make it difficult to see actual changes in the notebook content. Fortunately, there are tools to help to filter the cruft out and make notebooks play nicer with Git and diff. Here is another option to do the same with Jupyter's nbconvert and one splitting the notebook. And here is how to add controls on the GitHub repo.
Last but not least, a Git cheat sheet (also in PDF) with 50 useful git commands