Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Git 1 2 3

Git 1 2 3

A quick introduction to git

Avatar for Jordan Schatz

Jordan Schatz

June 15, 2011
Tweet

Other Decks in Technology

Transcript

  1. Git 1 2 3! A fast introduction to git for

    professionals Jordan Schatz [email protected] You can fork this presentation at: https://github.com/shofetim/git-1-2-3 1
  2. What is Git? Linus Torvolds wrote Git to solve a

    problem + All existing version control systems where broken + There where about 30,000 developers working on the kernel which made other VCS painful to use + He needed something that made his work faster 4
  3. Quick Note Why the name ’git’ ? Quoting Linus: "I’m

    an egotistical ***, and I name all my projects after myself. First ’Linux’, now ’git’" 6
  4. What is Git good for? Git is a Source Code

    Management system, not a version control system. 7
  5. What is Git good for? Git is a Source Code

    Management system, not a version control system. + Efficient Sharing 8
  6. What is Git good for? Git is a Source Code

    Management system, not a version control system. + Efficient Sharing + Code Review 9
  7. What is Git good for? Git is a Source Code

    Management system, not a version control system. + Efficient Sharing + Code Review + Documentation 10
  8. What is Git good for? Git is a Source Code

    Management system, not a version control system. + Efficient Sharing + Code Review + Documentation + Security / Integrity 11
  9. What is Git good for? Git is a Source Code

    Management system, not a version control system. + Efficient Sharing + Code Review + Documentation + Security / Integrity + Versioning 12
  10. What is Git good for? Git is a Source Code

    Management system, not a version control system. + Efficient Sharing + Code Review + Documentation + Security / Integrity + Versioning + Debugging 13
  11. What is Git good for? Git is a Source Code

    Management system, not a version control system. + Efficient Sharing + Code Review + Documentation + Security / Integrity + Versioning + Debugging + A simple continuous integration server 14
  12. What is Git good for? Git is a Source Code

    Management system, not a version control system. + Efficient Sharing + Code Review + Documentation + Security / Integrity + Versioning + Debugging + A simple continuous integration server + more cool tools 15
  13. Types of code that I use git for: + Ledger

    https://github.com/jwiegley/ledger 19
  14. Types of code that I use git for: + Emacs

    Org mode http://orgmode.org/ Appointments Notes Project management Time logs Passwords Project Proposals Research papers Code documentation 20
  15. Types of code that I use git for: + Calendar

    http://www.roaringpenguin.com/products/remind 21
  16. Types of code that I use git for: + Diagrams

    http://ditaa.sourceforge.net/ 22
  17. Types of code that I use git for: + Presentations

    http://docs.racket-lang.org/slideshow/index.html 23
  18. Types of code that I use git for: + Just

    about everything else too 24
  19. How it works + Commits + sha1 (sha1 (open-input-string "hello

    world")) "2aae6c35c94fcfb415dbe95f408b9ce91ee846ed" 29
  20. How it works + Commits + sha1 (sha1 (open-input-string "hello

    world")) "2aae6c35c94fcfb415dbe95f408b9ce91ee846ed" + diff & patch 30
  21. How it works + Commits + sha1 (sha1 (open-input-string "hello

    world")) "2aae6c35c94fcfb415dbe95f408b9ce91ee846ed" + diff & patch + working directory | index | repository 31
  22. Git Commands git config Get and set repository or global

    options. git config --global user.name "Jordan Schatz" git config --global user.email "[email protected]" 34
  23. Git Commands git mv Move or rename a file, a

    directory, or a symlink. 68
  24. Gotcha’s + Git tracks content, not files. + .gitignore +

    git push (it does the right thing but) 74
  25. Gotcha’s + Git tracks content, not files. + .gitignore +

    git push (it does the right thing but) + making commits/checkouts as root 75
  26. Gotcha’s + Git tracks content, not files. + .gitignore +

    git push (it does the right thing but) + making commits/checkouts as root + chmod’ing the hooks when you didn’t mean too... 76
  27. Tools + Github https://github.com/ + Deploy HQ http://www.deployhq.com/ + Gource

    http://code.google.com/p/gource/ + Gitosis http://scie.nti.st/2007/11/14/ hosting-git-repositories-the-easy-and-secure-way 80