An introduction to Git.
Upcoming SlideShare
Loading in...5
×
 

An introduction to Git.

on

  • 547 views

an introduction to git for the students of the multimedia 2012 course at KULeuven.

an introduction to git for the students of the multimedia 2012 course at KULeuven.

Statistics

Views

Total Views
547
Views on SlideShare
547
Embed Views
0

Actions

Likes
0
Downloads
3
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as Apple Keynote

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n

An introduction to Git. An introduction to Git. Presentation Transcript

  • Sten Govaerts KU Leuven
  • what the hell...• distributed version control
  • what the hell...• distributed version control• originally designed and developed by Linus Thorvalds.
  • what the hell...• distributed version control• originally designed and developed by Linus Thorvalds.• git (plural gits) (noun) • (UK, slang, pejorative) A contemptible person. • (UK, slang, pejorative) A silly, incompetent, stupid, annoying or childish person.
  • distributed? centralised distributedversion control version control GIT SVN or CVS http://www.slideshare.net/lydian/git-tutorial
  • but why?...• easier offline usage
  • but why?...• easier offline usage• easier to branch projects
  • but why?...• easier offline usage• easier to branch projects• git is good at merging files and re-joining branches
  • git philosophy• Commit early, commit often!• 1 commit = 1 idea or change • easy to read patches by team members • easy to revert changes later• local repo is your working directory
  • why do we need this?• group work • help each other• work on multiple locations• common back-end development?• learning analytics
  • how does it work? file states • modified • staged • commited
  • how does it work?
  • how does it work? dev B shared repo dev A dev C
  • how does it work? dev B git clone shared repo dev A dev C
  • how does it work? dev B sharedgit push repo dev A dev C
  • how does it work? dev B sharedgit push repo dev A dev C
  • how does it work? dev B sharedgit push repo git push dev A dev C
  • how does it work? dev B sharedgit push repo git push dev A dev C
  • how does it work? dev B sharedgit push repo dev A dev C
  • how does it work? dev B shared git fetchgit push repo git merge dev A dev C
  • • http://www.github.com• make an account (use twitter name) and one repository per group• put repository link on wiki • http://ariadne.cs.kuleuven.be/wiki
  • what do you do next?• student A makes the github repository
  • what do you do next?• student A makes the github repository• student A commits his work to his local repository and pushes to github
  • what do you do next?• student A makes the github repository• student A commits his work to his local repository and pushes to github• student B fetches the repository, commits his work locally and pushes to github
  • what do you do next?• student A makes the github repository• student A commits his work to his local repository and pushes to github• student B fetches the repository, commits his work locally and pushes to github• student C fetches the repository, commits his work locally and pushes to github
  • how to do this?• command line (4 1337 h4x0rz)• IDE tools • eclipse (http://www.vogella.com/articles/EGit/article.html) • xcode (http://support.beanstalkapp.com/customer/portal/ articles/95580-setting-up-git-with-xcode-4 & http:// developer.apple.com/library/mac/#recipes/xcode_help- repositories_organizer/articles/ CommittingFilestoaRepository.html#//apple_ref/doc/uid/ TP40010350-CH8-SW1)
  • tools• http://eclipse.github.com/• http://windows.github.com/• http://mac.github.com/
  • git commands cheat sheet• http://www.git-tower.com/files/cheatsheet/ Git_Cheat_Sheet_grey.pdf
  • further reading...• Setup github• Create a repo on github• Fork a repo• Everyday GIT with 20 commands or so• Advanced GIT tutorial• GITcasts• Git docs