SlideShare a Scribd company logo
Nathaniel Schweinberg
       @nathanielks
    FightTheCurrent.org
What the git?
git is a Source Control
Management application
   It keeps track of your code!
What the Git? - WordCamp Atlanta
git stores only the changes
         you make
What the Git? - WordCamp Atlanta
git allows you to focus
on the feature you’re
        writing
http://hades.name/blog/2010/01/22/git-your-friend-not-foe-vol-2-branches/
git allows multiple developers to
    work on the same project
http://git-scm.com/about/distributed
How to get started!
Step 1: Install git




      http://git-scm.com/book/en/Getting-Started-Installing-Git
Step 2: OPEN TERMINAL
What the Git? - WordCamp Atlanta
Step 3: Get it set up




      http://git-scm.com/book/en/Getting-Started-First-Time-Git-Setup
What the Git? - WordCamp Atlanta
What the Git? - WordCamp Atlanta
How git works




          http://git-scm.com/about/staging-area
git init
Initializes a git repository
      in current folder
git add .
   Adds file . to the staging area
( . means current folder and all files inside )
git commit –m ‘initial commit’
 Commits files added to staging area
       ( -m adds commit message )
What the Git? - WordCamp Atlanta
git status
Shows current status of
  working directory
http://git-scm.com/book/en/Git-Basics-Recording-Changes-to-the-Repository
What the Git? - WordCamp Atlanta
BRANCHING
Branching encourages
     a few things
Frictionless Context Switching
   Feature Based Workflow
 Disposable Experimentation



                            http://git-scm.com/about
What the Git? - WordCamp Atlanta
git branch name
Create new branch to work from
git checkout branchname
 Sets working tree to branchname
What the Git? - WordCamp Atlanta
git checkout –b branchname
Create and checkout into branchname
What the Git? - WordCamp Atlanta
What the Git? - WordCamp Atlanta
git merge branchname
Merges committed changes made in
 branchname with current branch
Repositories!
What the Git? - WordCamp Atlanta
Let’s add a remote repository
What the Git? - WordCamp Atlanta
Two basic actions
    git push              git pull
Pushes changes to    Pulls changes from
   remote repo          remote repo
Let’s integrate with
   WordPress!
What the Git? - WordCamp Atlanta
git clone
Use git clone to duplicate
a remote repository locally
What the Git? - WordCamp Atlanta
Submodules!
  Submodules allow you to keep separate
sections of your code under source control
            ( repos within repos )
git submodule add
         repository
      path/to/location
Adds submodule located at repository to
    path/to/location within project
What the Git? - WordCamp Atlanta
.gitignore
Use .gitignore to prevent files
from being added to the repo
What the Git? - WordCamp Atlanta
Let’s Talk strategy
Commit early,
Commit Often
Use descriptive commit
     messages!
Master branch is stable
       ONLY.
Always develop on a separate branch
Branch naming:
initials/feature-name
    ns/some-cool-feature
Working with multiple
       Devs
git rebase branchname
Updates current branch with changes made
               in another
Resources:
http://bit.ly/WhatTheGit
Nathaniel Schweinberg
       @nathanielks
    FightTheCurrent.org

More Related Content

PPTX
Git tutorial
PPTX
From svn to git
PDF
Version Control Systems with git (and github) as an example
PDF
Advance workshop on git
PDF
Git in 5 Minutes
PPTX
Extra bit with git
PPTX
Extra bit with git
PDF
Git Version Control System
Git tutorial
From svn to git
Version Control Systems with git (and github) as an example
Advance workshop on git
Git in 5 Minutes
Extra bit with git
Extra bit with git
Git Version Control System

What's hot (20)

PDF
Git tutorial
ODP
Git presentation
PDF
Git for beginners
PPT
Git basic
PPTX
Introduction to git and github
PDF
Version Control System - Git
PDF
Version Control & Git
PPTX
Git - Basic Crash Course
PDF
Collaborative development with Git | Workshop
PPTX
Git tutorial
PDF
Git and GitHub workflows
PDF
Git Tutorial
PPT
Git Introduction
PDF
Version Control History and Git Basics
PPTX
Luis atencio on_git
PPTX
Git learning
PPTX
Quick and easy way to get started with Git & GitHub
PPTX
Git in 10 minutes
PPTX
Git basics to advance with diagrams
PPT
GIT By Sivakrishna
Git tutorial
Git presentation
Git for beginners
Git basic
Introduction to git and github
Version Control System - Git
Version Control & Git
Git - Basic Crash Course
Collaborative development with Git | Workshop
Git tutorial
Git and GitHub workflows
Git Tutorial
Git Introduction
Version Control History and Git Basics
Luis atencio on_git
Git learning
Quick and easy way to get started with Git & GitHub
Git in 10 minutes
Git basics to advance with diagrams
GIT By Sivakrishna
Ad

Similar to What the Git? - WordCamp Atlanta (20)

PDF
Version Control Systems Software Engineering
PDF
PDF
Git for developers
PPTX
Introduction to Git and Github
DOCX
setting up a repository using GIT
PPTX
Hacktoberfest intro to Git and GitHub
PPTX
Git training (basic)
PPTX
PDF
Introducing Git and git flow
PPTX
GitHub and Open Source - GDGoC MIT Anna University
PPTX
PDF
PDF
Git 入门与实践
PDF
Git 入门 与 实践
PPTX
Git 101
DOCX
Git github
PDF
Git slides
PDF
Git cheat sheet
PPTX
1-Intro to VC & GIT PDF.pptx
PPTX
Git hub visualstudiocode
Version Control Systems Software Engineering
Git for developers
Introduction to Git and Github
setting up a repository using GIT
Hacktoberfest intro to Git and GitHub
Git training (basic)
Introducing Git and git flow
GitHub and Open Source - GDGoC MIT Anna University
Git 入门与实践
Git 入门 与 实践
Git 101
Git github
Git slides
Git cheat sheet
1-Intro to VC & GIT PDF.pptx
Git hub visualstudiocode
Ad

What the Git? - WordCamp Atlanta