Awesome
BU CNSO Git Introduction
This repository exists to get people used to git commands and the GitHub interface.
Prerequisites
The following steps are required of anybody participating in this introduction.
- Sign up for a GitHub account
- Request to join the bu-cnso group by emailing me. (Or the list, if you don't know my email.)
- Install git on your laptop
- You can also use a git installation on a server you can SSH into.
- The GitHub client doesn't count. 1. Except that's the way GitHub recommends you to install git on Windows. We won't be discussing the graphical client, so make sure you can do step 5 from the command-line.
- Add a public key to your GitHub account. The private key should be on the computer you plan to use.
- Create an initial repository for your user and follow the instructions to make an initial commit.
Lesson plan
Note that lines beginning with $
are shell commands, and the lines following
it are example output. Do not type the $
prompt.
Begin by setting the USER variable to your GitHub username:
$ export USER=...
Or just note that whenever you see $USER
, you're supposed to put in your
username.
Some very quick terminology
A repository is a directory, its contents, and its history.
A commit is a snapshot of the directory contents. A commit usually has one parent, sometimes two, and rarely zero.
The history of the repository is a collection of commits.
Topics
The Cheat Sheet
This page will see you through most situations you're likely to run into: Git Cheat Sheet
About README.md
This file is written in Markdown, a simple markup language.