This document provides an introduction to using Git and GitHub for version control of documents and collaboration. It explains the basic workflow of creating, editing, and saving files individually. It then introduces Git as a tool to track changes to documents over time, including who made each change and when. The document outlines setting up Git locally and using basic commands like commit, diff, log, branch, merge, and push/pull to the remote GitHub repository. It highlights key GitHub features like the profile page, repository page, pull requests, and hosting websites for free using GitHub Pages.
8. Hence one more question
For each document version, we need to know
1. When the 鍖le was modi鍖ed
2. What changed
3. Why it was modi鍖ed
4. Who did the change
9. In a nutshell
We want a tool which
1. tracks document version
2. keeps an history of document changes
3. foster team work
17. 2-steps process
# Select which file to add to the commit.
$ git add <file_1_which_has_been_modified>
$ git add <file_2_which_has_been_modified>
# Take a snapshot of what is in the staging area.
$ git commit --message "A meaningful message about this change"
18. Diff
If git status tells you something changed,
you can inspect exactly what changed:
$ git diff
$ git diff <a_specific_file_or_folder>