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

Git - I'm lovin' it

Git - I'm lovin' it

A short presentation about using git for beginners

Amir Friedman

March 19, 2013
Tweet

More Decks by Amir Friedman

Other Decks in Programming

Transcript

  1. Traditional Version Control • SLOW • COMPLICATED to branch •

    Branches are COPIES • Merging is ANNOYING • SLOW • Not always free • Requires a centralized server • Can't always work offline A new world of PAIN
  2. Git == AWESOME • FAST • Developers can work offline

    • Local Control • Much smaller compared to other repos, e.g: Mozilla (SVN), 30x smaller • Branches carry their entire history • DECENTRALIZED • ANY workflow is possible
  3. git init 8:45 ➜ restaurant> git init Initialized empty Git

    repository in /Users/amirf/restaurant/.git/ 8:45 ➜ restaurant git:(master) ✗> Master is not special, it's just the default.
  4. git status 8:52 ➜ restaurant git:(master) ✗ git status #

    On branch master # *snip snip* # # new file: rest_task1.c # 8:54 ➜ restaurant git:(master) ✗
  5. git merge <name> 9:45 git:(master) ➜ git merge new-feature 9:45

    git:(master) ➜ git merge remotes/origin/new-feature
  6. git stash ➜ git stash save ➜ git stash list

    ➜ git stash pop ➜ git stash apply stash@{0} ➜ git stash drop stash@{0} the 'stash
  7. DEMO TIME! Let's create a repository and do some branching,

    merging and revet. ...and then let's do it on plugins-repo.