lectures‎ > ‎

lecture 29

Monday 4/11/2011

Video: http://dennett.cs-i.brandeis.edu/cs177/L29

Collaborative Programming with GIT  http://git-scm.com
  • the problem - several people working on a set of files and folders effectively
  • the solution - keep several versions, be able to merge versions, keep main versions on shared server
  • the tools - GIT which is what we use.  Others: cvs, subversion, mercurial, ...

Read Chapters 1,2,3,4 of the GIT book http://progit.org/book
We will also go over the tutorial http://gitref.org
For windows users, you may want to read http://help.github.com/win-set-up-git
and if you use windows and don't want to use the command line read

Class Plan:
  1. Go over hw6 and introduce GIT in the process
  2. Go over the use of GIT for the final project
Notes on GIT
(follow the git reference document http://gitref.org )
  • GIT stores snapshots of collections of files in a very efficient manner (review page 1 of gitref.org)
  • Creating an initial GIT repository (by init or by clone) (review page 2)
    • git init
    • git help COMMAND
  • git add, status, diff, commit  -- putting files into the staging area and the repository
    • git add FOLDER
    • git status
    • git diff
    • git commit
  • git branch, checkout, merge, log, tag  -- creating a tree of multiple versions
    • git branch NEWNAME
    • git checkout BRANCHNAME
    • git merge BRANCHNAME
    • git log
    • git tag TAGNAME
  • git remote, git remote add -- connecting to remote servers
    • git remote
    • git remote add ALIAS URL
  • git fetch ALIAS, git merge ALIAS/BRANCH, git push ALIAS BRANCH
    • git fetch ALIAS
    • git merge ALIAS/BRANCH
    • git push ALIAS BRANCH