1. Git Introduction

1.1. About Version Control

1.1.1. Why we have Version Control?

1.1.2. Centralized vs. Decentralized

  1. Centralized:

    • Single truth

    • Simple revision numbers

    • Timeline is always straight

    • Single point of failure

    • Simpler branches

    • Small number of branches

  2. Decentralized

    • Unable to use incremented int as revision numbers

    • Use hashes

    • All repositories are equal

    • Any repository can have different history

    • More diverged branches

    • Can have many branches

1.2. Design Philosophy

  1. Tracking file permissions

  2. Tracking file renames and moves

  3. Key-Value Storage of Immutable Objects

  4. Working Offline

  5. Efficient Storage

1.3. Use Cases

1.4. Assignments

1.4.1. SSH key

  1. Create and login to Github account

  2. If you don’t have .ssh/id_rsa lub .ssh/id_rsa.pub run command ssh-keygen

  3. Add your.email@example.com/hostname to the end of your public key ~/.ssh/id_rsa.pub (as a comment)

  4. Add ssh public key ~/.ssh/id_rsa.pub to Github profile

1.4.2. Repository Hosting

  1. create accounts

  2. create repo

  3. protect branches

  4. add collaborators

  5. clone & touch .gitignore & push

  6. pull-request