SlideShare a Scribd company logo
1 of 297
Git and GitHub
The unabridged story
BUT FIRST A WORD FROM OUR SPONSOR
BUT FIRST A WORD FROM OUR SPONSOR
BUT FIRST A WORD FROM OUR SPONSOR
HAPPY BIRTHDAY DANA!
Git
The stupid content tracker
What is Git, really?
Intelligence Check
Intelligence Check
Subversion is a smart database of file differences
Intelligence Check
Subversion is a smart database of file differences

  Unfortunately, this makes it quite complex
Intelligence Check
Subversion is a smart database of file differences

  Unfortunately, this makes it quite complex

Git is pretty stupid
Intelligence Check
Subversion is a smart database of file differences

  Unfortunately, this makes it quite complex

Git is pretty stupid

  Stores trees of content, much like a file system
Intelligence Check
Subversion is a smart database of file differences

  Unfortunately, this makes it quite complex

Git is pretty stupid

  Stores trees of content, much like a file system

  A commit creates a new tree reachable by name
Intelligence Check
Subversion is a smart database of file differences

  Unfortunately, this makes it quite complex

Git is pretty stupid

  Stores trees of content, much like a file system

  A commit creates a new tree reachable by name

  It can change your directory to recreate any tree
Git Isn’t Really an SCM
Git Isn’t Really an SCM
Git does Source Code Management and
Git Isn’t Really an SCM
Git does Source Code Management and

 Peer to peer content distribution
Git Isn’t Really an SCM
Git does Source Code Management and

 Peer to peer content distribution

 Document database
Git Isn’t Really an SCM
Git does Source Code Management and

 Peer to peer content distribution

 Document database

   Distributed wiki
Git Isn’t Really an SCM
Git does Source Code Management and

 Peer to peer content distribution

 Document database

   Distributed wiki

   Distributed issue tracker
Git Isn’t Really an SCM
Git does Source Code Management and

 Peer to peer content distribution

 Document database

   Distributed wiki

   Distributed issue tracker

 Backups
The Plusses of
a Simple Design
The Plusses of
a Simple Design
It was designed to manage the development of the
Linux kernel (a very large code base)
The Plusses of
a Simple Design
It was designed to manage the development of the
Linux kernel (a very large code base)

  Git is very efficient
The Plusses of
a Simple Design
It was designed to manage the development of the
Linux kernel (a very large code base)

  Git is very efficient

  Git handles non-linear development with grace
The Plusses of
a Simple Design
It was designed to manage the development of the
Linux kernel (a very large code base)

  Git is very efficient

  Git handles non-linear development with grace

  Git is distributed from the ground up
SOMETIMES YOU HAVE A TOILET IN YOUR YARD
SOMETIMES YOU HAVE A TOILET IN YOUR YARD
AND WHO WANTS THAT, REALLY?
The Minuses of
the Toolkit Design
The Minuses of
the Toolkit Design
Git provides a ton of commands to interact with it
The Minuses of
the Toolkit Design
Git provides a ton of commands to interact with it

  The “porcelain” commands are the ones you
  typically interact with
The Minuses of
the Toolkit Design
Git provides a ton of commands to interact with it

  The “porcelain” commands are the ones you
  typically interact with

  The lower-level “plumbing” commands are crazy
  powerful, but less user friendly
The Minuses of
the Toolkit Design
Git provides a ton of commands to interact with it

  The “porcelain” commands are the ones you
  typically interact with

  The lower-level “plumbing” commands are crazy
  powerful, but less user friendly

This can add up to make Git a little intimidating
Installing and Configuring
IF YOU BUILD IT, THEY WILL COME
IF YOU BUILD IT, THEY WILL COME
IF YOU BUILD IT, THEY WILL COME
SOMETIMES YOU JUST HAVE TO INSTALL A RIDICULOUS ROBOT
OFFICIAL SITE: HTTP://GIT-SCM.COM/
THERE ARE BINARIES FOR SOME PLATFORMS
OFFICIAL SITE: HTTP://GIT-SCM.COM/
THERE ARE BINARIES FOR SOME PLATFORMS
OFFICIAL SITE: HTTP://GIT-SCM.COM/
THERE ARE BINARIES FOR SOME PLATFORMS
THE INSTRUCTIONS I USE TO BUILD ON MAC OS X
THESE SIDESTEP THE DOCUMENTATION AND MACPORTS REQUIREMENTS
THE INSTRUCTIONS I USE TO BUILD ON MAC OS X
THESE SIDESTEP THE DOCUMENTATION AND MACPORTS REQUIREMENTS
Git is still young and
growing fast (update to 1.7)
[user]
                     name = James Edward Gray II
                     email = james@graysoftinc.com
                   [apply]
                     whitespace = nowarn
                   [color]
                     status = auto
                     branch = auto
                     interactive = auto
                     repositoryformatversion = 0
                     filemode = true
                     bare = false
                     logallrefupdates = true
                   [gc]
                     auto = 1
                   [github]
                     user = JEG2
                     token = …

~/.GITCONFIG
THESE ARE SOME VERY HELPFUL GIT INTERFACE SETTINGS
[user]
                     name = James Edward Gray II
                     email = james@graysoftinc.com
                   [apply]
                     whitespace = nowarn
                   [color]
                     status = auto
                     branch = auto
                     interactive = auto
                     repositoryformatversion = 0
                     filemode = true
                     bare = false
                     logallrefupdates = true
                   [gc]
                     auto = 1
                   [github]
                     user = JEG2
                     token = …

~/.GITCONFIG
THESE ARE SOME VERY HELPFUL GIT INTERFACE SETTINGS
[user]
                     name = James Edward Gray II
                     email = james@graysoftinc.com
                   [apply]
                     whitespace = nowarn
                   [color]
                     status = auto
                     branch = auto
                     interactive = auto
                     repositoryformatversion = 0
                     filemode = true
                     bare = false
                     logallrefupdates = true
                   [gc]
                     auto = 1
                   [github]
                     user = JEG2
                     token = …

~/.GITCONFIG
THESE ARE SOME VERY HELPFUL GIT INTERFACE SETTINGS
[user]
                     name = James Edward Gray II
                     email = james@graysoftinc.com
                   [apply]
                     whitespace = nowarn
                   [color]
                     status = auto
                     branch = auto
                     interactive = auto
                     repositoryformatversion = 0
                     filemode = true
                     bare = false
                     logallrefupdates = true
                   [gc]
                     auto = 1
                   [github]
                     user = JEG2
                     token = …

~/.GITCONFIG
THESE ARE SOME VERY HELPFUL GIT INTERFACE SETTINGS
set   mainfont {Monaco 12}
             set   textfont {Monaco 12}
             set   uifont {"Monaco Bold" 12}
             set   tabstop 8
             set   findmergefiles 0
             set   maxgraphpct 50
             set   maxwidth 16
             set   cmitmode patch
             set   wrapcomment none
             set   showneartags 1
             set   showlocalchanges 1
             set   datetimeformat {%Y-%m-%d %H:%M:%S}
             set   limitdiffs 1
             set   bgcolor white
             set   fgcolor black
             set   colors {green red blue magenta darkgrey brown orange}
             set   diffcolors {red "#00a000" blue}
             set   diffcontext 3
             set   selectbgcolor gray85
             set   geometry(main) 794x484+5+45
             set   geometry(topwidth) 790
             set   geometry(topheight) 150
             set   geometry(pwsash0) "280 2"
             set   geometry(pwsash1) "420 2"
             set   geometry(botwidth) 350
             set   geometry(botheight) 314
             set   permviews {}


~/.GITK
THESE SETTINGS CLEAN UP THE INCLUDED GUI
# Git
                      alias g="git status"
                      alias ga="git add"
                      alias gaa="git add ."
                      alias gc="git commit -m"
                      alias gca="git commit -am"
                      alias gb="git branch"
                      alias gbd="git branch -d"
                      alias gco="git checkout"
                      alias gcob="git checkout -b"
                      alias gm="git merge"
                      alias gr="git rebase"
                      alias gl="git log"
                      alias gs="git show"
                      alias gd="git diff"
                      alias gbl="git blame"
                      alias gps="git push"
                      alias gpl="git pull"

~/.BASHRC
THESE ARE SOME BASH ALIASES I USE
# Git
                      alias g="git status"
                      alias ga="git add"
                      alias gaa="git add ."
                      alias gc="git commit -m"
                      alias gca="git commit -am"
                      alias gb="git branch"
                      alias gbd="git branch -d"
                      alias gco="git checkout"
                      alias gcob="git checkout -b"
                      alias gm="git merge"
                      alias gr="git rebase"
                      alias gl="git log"
                      alias gs="git show"
                      alias gd="git diff"
                      alias gbl="git blame"
                      alias gps="git push"
                      alias gpl="git pull"

~/.BASHRC
THESE ARE SOME BASH ALIASES I USE
# Git
                      alias g="git status"
                      alias ga="git add"
                      alias gaa="git add ."
                      alias gc="git commit -m"
                      alias gca="git commit -am"
                      alias gb="git branch"
                      alias gbd="git branch -d"
                      alias gco="git checkout"
                      alias gcob="git checkout -b"
                      alias gm="git merge"
                      alias gr="git rebase"
                      alias gl="git log"
                      alias gs="git show"
                      alias gd="git diff"
                      alias gbl="git blame"
                      alias gps="git push"
                      alias gpl="git pull"

~/.BASHRC
THESE ARE SOME BASH ALIASES I USE
Memorize all of That?
Memorize all of That?

There’s a new trend to store your “dotfiles” online
Memorize all of That?

There’s a new trend to store your “dotfiles” online

  This makes it easy to move them
Memorize all of That?

There’s a new trend to store your “dotfiles” online

  This makes it easy to move them

  Plus we can all share
Memorize all of That?

There’s a new trend to store your “dotfiles” online

  This makes it easy to move them

  Plus we can all share

Surprise: A great place to find these is GitHub
Memorize all of That?

There’s a new trend to store your “dotfiles” online

  This makes it easy to move them

  Plus we can all share

Surprise: A great place to find these is GitHub

Mine are at: http://github.com/JEG2/dotfiles
Staging and Commits
DANA IS SAD
DANA IS SAD
DANA IS SAD
HER CRAFT ROOM IS TRANSITIONING INTO A NURSERY
STAGING A CHANGE, THEN COMMITTING
THIS IS A NORMAL WORKFLOW FOR CHANGES IN GIT
GIT STATUS




                                                     GIT ADD .

                                               GIT STATUS




                                               GIT COMMIT -M “FIRST COMMIT.”




STAGING A CHANGE, THEN COMMITTING
THIS IS A NORMAL WORKFLOW FOR CHANGES IN GIT
GIT STATUS




                                                     GIT ADD .

                                               GIT STATUS




                                               GIT COMMIT -M “FIRST COMMIT.”




STAGING A CHANGE, THEN COMMITTING
THIS IS A NORMAL WORKFLOW FOR CHANGES IN GIT
GIT STATUS




                                                     GIT ADD .

                                               GIT STATUS




                                               GIT COMMIT -M “FIRST COMMIT.”




STAGING A CHANGE, THEN COMMITTING
THIS IS A NORMAL WORKFLOW FOR CHANGES IN GIT
GIT STATUS




                                                     GIT ADD .

                                               GIT STATUS




                                               GIT COMMIT -M “FIRST COMMIT.”




STAGING A CHANGE, THEN COMMITTING
THIS IS A NORMAL WORKFLOW FOR CHANGES IN GIT
GIT STATUS




                                                     GIT ADD .

                                               GIT STATUS




                                               GIT COMMIT -M “FIRST COMMIT.”




STAGING A CHANGE, THEN COMMITTING
THIS IS A NORMAL WORKFLOW FOR CHANGES IN GIT
GIT DATA IS SHARED BY THREE AREAS
THE REPOSITORY HOLDS ALL POSSIBLE WORKING DIRECTORIES
THE WORKING DIRECTORY




GIT DATA IS SHARED BY THREE AREAS
THE REPOSITORY HOLDS ALL POSSIBLE WORKING DIRECTORIES
THE INDEX
                                                   OR
                                              STAGING AREA



GIT DATA IS SHARED BY THREE AREAS
THE REPOSITORY HOLDS ALL POSSIBLE WORKING DIRECTORIES
THE REPOSITORY




GIT DATA IS SHARED BY THREE AREAS
THE REPOSITORY HOLDS ALL POSSIBLE WORKING DIRECTORIES
GIT INCLUDES POWERFUL INSPECTION TOOLS
A SHA1 HASH (40 CHARACTERS) IS HOW GIT NAMES EVERYTHING
GIT LOG




                                                          GIT SHOW 96987

                                                          GIT SHOW 5F3F6




                                                            GIT BLAME README



GIT INCLUDES POWERFUL INSPECTION TOOLS
A SHA1 HASH (40 CHARACTERS) IS HOW GIT NAMES EVERYTHING
GIT LOG




                                                          GIT SHOW 96987

                                                          GIT SHOW 5F3F6




                                                            GIT BLAME README



GIT INCLUDES POWERFUL INSPECTION TOOLS
A SHA1 HASH (40 CHARACTERS) IS HOW GIT NAMES EVERYTHING
GIT LOG




                                                          GIT SHOW 96987

                                                          GIT SHOW 5F3F6




                                                            GIT BLAME README



GIT INCLUDES POWERFUL INSPECTION TOOLS
A SHA1 HASH (40 CHARACTERS) IS HOW GIT NAMES EVERYTHING
GIT LOG




                                                          GIT SHOW 96987

                                                          GIT SHOW 5F3F6




                                                            GIT BLAME README



GIT INCLUDES POWERFUL INSPECTION TOOLS
A SHA1 HASH (40 CHARACTERS) IS HOW GIT NAMES EVERYTHING
GIT LOG




                                                          GIT SHOW 96987

                                                          GIT SHOW 5F3F6




                                                            GIT BLAME README



GIT INCLUDES POWERFUL INSPECTION TOOLS
A SHA1 HASH (40 CHARACTERS) IS HOW GIT NAMES EVERYTHING
GIT LOG




                                                          GIT SHOW 96987

                                                          GIT SHOW 5F3F6




                                                            GIT BLAME README



GIT INCLUDES POWERFUL INSPECTION TOOLS
A SHA1 HASH (40 CHARACTERS) IS HOW GIT NAMES EVERYTHING
Branching and Merging
YOU CAN ADD BRANCHES TO ANYTHING
YOU CAN ADD BRANCHES TO ANYTHING
YOU CAN ADD BRANCHES TO ANYTHING
A KID, YOUR SOURCE CODE, OR WHATEVER
Using Git without branches
is like buying condoms
and not having any sex
GIT WAS MADE TO BRANCH, LITERALLY!
WHEN YOU BRANCH, GIT HAS TO WRITE 40 CHARACTERS TO A FILE (SUPER CHEAP)!
GIT WAS MADE TO BRANCH, LITERALLY!
WHEN YOU BRANCH, GIT HAS TO WRITE 40 CHARACTERS TO A FILE (SUPER CHEAP)!
GIT WAS MADE TO BRANCH, LITERALLY!
WHEN YOU BRANCH, GIT HAS TO WRITE 40 CHARACTERS TO A FILE (SUPER CHEAP)!
GIT WAS MADE TO BRANCH, LITERALLY!
WHEN YOU BRANCH, GIT HAS TO WRITE 40 CHARACTERS TO A FILE (SUPER CHEAP)!
THE INCLUDED GITK SHOWS BRANCHES
PASS THE --ALL FLAG TO SEE BRANCHES YOU AREN’T CURRENTLY ON
THE INCLUDED GITK SHOWS BRANCHES
PASS THE --ALL FLAG TO SEE BRANCHES YOU AREN’T CURRENTLY ON
GIT MERGE PULLS THE NAMED BRANCH IN
UNLIKE SUBVERSION, GIT MERGE IS POWERFUL, SMART, AND EASY TO USE
GIT MERGE PULLS THE NAMED BRANCH IN
UNLIKE SUBVERSION, GIT MERGE IS POWERFUL, SMART, AND EASY TO USE
GIT MERGE PULLS THE NAMED BRANCH IN
UNLIKE SUBVERSION, GIT MERGE IS POWERFUL, SMART, AND EASY TO USE
GIT MERGE PULLS THE NAMED BRANCH IN
UNLIKE SUBVERSION, GIT MERGE IS POWERFUL, SMART, AND EASY TO USE
THE HISTORY SHOWS THE INCORPORATED BRANCH
EVEN AFTER THE BRANCH IS DELETED, GIT REMEMBERS WHERE IT CAME FROM
THE HISTORY SHOWS THE INCORPORATED BRANCH
EVEN AFTER THE BRANCH IS DELETED, GIT REMEMBERS WHERE IT CAME FROM
THE HISTORY SHOWS THE INCORPORATED BRANCH
EVEN AFTER THE BRANCH IS DELETED, GIT REMEMBERS WHERE IT CAME FROM
THE HISTORY SHOWS THE INCORPORATED BRANCH
EVEN AFTER THE BRANCH IS DELETED, GIT REMEMBERS WHERE IT CAME FROM
REBASE CAN BE USED TO FLATTEN THE HISTORY
YOU CAN CHOOSE TO ADD A BRANCH ONTO THE END OF ANOTHER BRANCH
REBASE CAN BE USED TO FLATTEN THE HISTORY
YOU CAN CHOOSE TO ADD A BRANCH ONTO THE END OF ANOTHER BRANCH
REBASE CAN BE USED TO FLATTEN THE HISTORY
YOU CAN CHOOSE TO ADD A BRANCH ONTO THE END OF ANOTHER BRANCH
NOW THE MERGED HISTORY IS JUST A FLAT LINE
GIT REPLAYED OUR CHANGES ONTO THE END OF THE MASTER BRANCH
With Git, it’s never too late
to branch!
YOU CAN STILL BRANCH AFTER CHANGES
IF A PROBLEM STARTS TO LOOK BIG AFTER WORKING ON IT, MOVE IT INTO A BRANCH
YOU CAN STILL BRANCH AFTER CHANGES
IF A PROBLEM STARTS TO LOOK BIG AFTER WORKING ON IT, MOVE IT INTO A BRANCH
GIT STASH CAN HOLDS SOME CHANGES FOR LATER
I USE THIS WHEN I GET INTERRUPTED AND NEED TO SWITCH GEARS
GIT STASH CAN HOLDS SOME CHANGES FOR LATER
I USE THIS WHEN I GET INTERRUPTED AND NEED TO SWITCH GEARS
GIT STASH CAN HOLDS SOME CHANGES FOR LATER
I USE THIS WHEN I GET INTERRUPTED AND NEED TO SWITCH GEARS
Editing History
DANA REVISED HER OWN HISTORY
DANA REVISED HER OWN HISTORY
DANA REVISED HER OWN HISTORY
DANA REVISED HER OWN HISTORY
SHE THREW OUT ABOUT 60 COMMITS… ERR, POUNDS
Git Trusts you With
the Scary Power Tools
Git Trusts you With
the Scary Power Tools
Several Git commands can be used to revise the
commit history
Git Trusts you With
the Scary Power Tools
Several Git commands can be used to revise the
commit history

Total rewrites are possible
Git Trusts you With
the Scary Power Tools
Several Git commands can be used to revise the
commit history

Total rewrites are possible

  Some consider this very evil
Git Trusts you With
the Scary Power Tools
Several Git commands can be used to revise the
commit history

Total rewrites are possible

  Some consider this very evil

Let me show you two lighter uses that I consider
practical
YOU CAN AMEND (OR ADD TO) A COMMIT
THIS IS AWESOME PERFECT FOR WHEN YOU FORGET TO ADD A FILE
YOU CAN AMEND (OR ADD TO) A COMMIT
THIS IS AWESOME PERFECT FOR WHEN YOU FORGET TO ADD A FILE
YOU GET A CHANCE TO REVISE THE MESSAGE
AS YOU CAN SEE, I HAVE TEXTMATE SET AS MY EDITOR
THE TWO COMMITS BECAME ONE
NOTICE HOW ALL ASPECTS OF THE SECOND COMMIT WERE ROLLED INTO THE FIRST
THE TWO COMMITS BECAME ONE
NOTICE HOW ALL ASPECTS OF THE SECOND COMMIT WERE ROLLED INTO THE FIRST
GIT CAN “CHERRY PICK” COMMITS
YOU AREN’T REQUIRED TO TAKE COMMITS IN ORDER
GIT CAN “CHERRY PICK” COMMITS
YOU AREN’T REQUIRED TO TAKE COMMITS IN ORDER
GIT CAN “CHERRY PICK” COMMITS
YOU AREN’T REQUIRED TO TAKE COMMITS IN ORDER
Git Speaks Subversion
WHEELCHAIRS CAN RIDE JAPAN’S TRAINS
WHEELCHAIRS CAN RIDE JAPAN’S TRAINS
WHEELCHAIRS CAN RIDE JAPAN’S TRAINS
BE SURE YOU SPEAK A LITTLE JAPANESE THOUGH, JUST IN CASE!
Git Ships With
Subversion Support
Git Ships With
Subversion Support
Checkout with: git svn clone SUBVERSION_URL
Git Ships With
Subversion Support
Checkout with: git svn clone SUBVERSION_URL

 Add --username=USER if needed
Git Ships With
Subversion Support
Checkout with: git svn clone SUBVERSION_URL

  Add --username=USER if needed

Update with: git svn rebase
Git Ships With
Subversion Support
Checkout with: git svn clone SUBVERSION_URL

  Add --username=USER if needed

Update with: git svn rebase

  Subversion requires a linear history, thus rebase
Git Ships With
Subversion Support
Checkout with: git svn clone SUBVERSION_URL

  Add --username=USER if needed

Update with: git svn rebase

  Subversion requires a linear history, thus rebase

Use Git to develop locally as normal
Git Ships With
Subversion Support
Checkout with: git svn clone SUBVERSION_URL

  Add --username=USER if needed

Update with: git svn rebase

  Subversion requires a linear history, thus rebase

Use Git to develop locally as normal

Commit all diffs to Subversion: git svn dcommit
Distributed Repositories
YOU CAN NEVER HAVE TOO FEW GEEKS
YOU CAN NEVER HAVE TOO FEW GEEKS
YOU CAN NEVER HAVE TOO FEW GEEKS
I NEED THIS MANY JUST TO PLAY A GAME ONCE A YEAR
git clone 
git://192.168.0.109/faster_csv
To Set That Up…
To Set That Up…
I created a git_server directory on my Desktop
To Set That Up…
I created a git_server directory on my Desktop

  I moved my faster_csv repository into it
To Set That Up…
I created a git_server directory on my Desktop

  I moved my faster_csv repository into it

I ran: git daemon --base-path=/Users/james/
Desktop/git_server --export-all
To Set That Up…
I created a git_server directory on my Desktop

  I moved my faster_csv repository into it

I ran: git daemon --base-path=/Users/james/
Desktop/git_server --export-all

This is read-only (but write support is possible)
access on port 9418
To Set That Up…
I created a git_server directory on my Desktop

  I moved my faster_csv repository into it

I ran: git daemon --base-path=/Users/james/
Desktop/git_server --export-all

This is read-only (but write support is possible)
access on port 9418

This rocks for when GitHub is down
http://192.168.0.109:1234/
An Instant
Web Interface
An Instant
Web Interface
I moved into the Git working directory
An Instant
Web Interface
I moved into the Git working directory

I ran: git instaweb --httpd=webrick
An Instant
Web Interface
I moved into the Git working directory

I ran: git instaweb --httpd=webrick

  Later, I will stop it with: git instaweb --stop
An Instant
Web Interface
I moved into the Git working directory

I ran: git instaweb --httpd=webrick

  Later, I will stop it with: git instaweb --stop

This is a handy poor man’s repository browser
that’s pretty much always available
Git Strategies
EVERYBODY HAS THEIR SYSTEM
EVERYBODY HAS THEIR SYSTEM
EVERYBODY HAS THEIR SYSTEM
EVERYBODY HAS THEIR SYSTEM
EVERYBODY HAS THEIR SYSTEM
EVERYBODY HAS THEIR SYSTEM
DANA HAS ONE JUST FOR FOOD
Git Supports
Many Work Styles
Git Supports
Many Work Styles
Git’s features make it very flexible
Git Supports
Many Work Styles
Git’s features make it very flexible

  Non-linear history is fully supported
Git Supports
Many Work Styles
Git’s features make it very flexible

  Non-linear history is fully supported

  Powerful history rewriting is provided
Git Supports
Many Work Styles
Git’s features make it very flexible

  Non-linear history is fully supported

  Powerful history rewriting is provided

  All repositories are masters
Git Supports
Many Work Styles
Git’s features make it very flexible

  Non-linear history is fully supported

  Powerful history rewriting is provided

  All repositories are masters

  Any repository can be distributed
Git Supports
Many Work Styles
Git’s features make it very flexible

  Non-linear history is fully supported

  Powerful history rewriting is provided

  All repositories are masters

  Any repository can be distributed

Many work strategies are built off of these features
Branch Strategies
SAY WE HAVE A BRANCH WITH TWO COMMITS
THIS IS A PRETTY TYPICAL GIT SCENARIO, A TOPIC BRANCH OFF OF MASTER
FAST FORWARD (A FLAT MERGE)
BY DEFAULT, GIT WOULD JUST ADD THESE COMMITS ONTO MASTER
YOU CAN FORCE GIT TO KEEP THE BRANCH
HTTP://NVIE.COM/GIT-MODEL
YOU CAN FORCE GIT TO KEEP THE BRANCH
HTTP://NVIE.COM/GIT-MODEL
NOTICE HOW GIT ADDED A MERGE COMMIT
YOU CAN REVERT THAT ONE COMMIT TO UNDO THE ENTIRE BRANCH
NOTICE HOW GIT ADDED A MERGE COMMIT
YOU CAN REVERT THAT ONE COMMIT TO UNDO THE ENTIRE BRANCH
ALTERNATELY, YOU COULD SQUASH THE COMMITS
HTTP://GEEWAX.ORG/2009/11/21/AGILE-GIT-WORKFLOW.HTML
ALTERNATELY, YOU COULD SQUASH THE COMMITS
HTTP://GEEWAX.ORG/2009/11/21/AGILE-GIT-WORKFLOW.HTML
REBASE ASKS ME HOW TO HANDLE EACH COMMIT
GIT COMMANDS LIKE ADD AND REBASE SUPPORT A POWERFUL INTERACTIVE MODE
REBASE ASKS ME HOW TO HANDLE EACH COMMIT
GIT COMMANDS LIKE ADD AND REBASE SUPPORT A POWERFUL INTERACTIVE MODE
YOU EVEN GET TO REVISE THE COMMITS
COMBINE OR REPLACE THEM TO TASTE
YOU EVEN GET TO REVISE THE COMMITS
COMBINE OR REPLACE THEM TO TASTE
FINALLY, MERGE THE COLLAPSED COMMIT
I CAN USE THE POWER OF INTERACTIVE MODE TO COLLAPSE THINGS INTO ONE COMMIT
FINALLY, MERGE THE COLLAPSED COMMIT
I CAN USE THE POWER OF INTERACTIVE MODE TO COLLAPSE THINGS INTO ONE COMMIT
A TOPIC BRANCH WAS REDUCED TO ONE COMMIT
THIS IS ANOTHER TECHNIQUE THAT ALLOWS US TO UNDO IT WITH ONE REVERT
A TOPIC BRANCH WAS REDUCED TO ONE COMMIT
THIS IS ANOTHER TECHNIQUE THAT ALLOWS US TO UNDO IT WITH ONE REVERT
Master Repository
Strategies
YOUR SUBVERSION STRATEGY STILL WORKS FINE
THIS IS HOW GITHUB IS COMMONLY USED
LINUS USES HIS “CIRCLE OF TRUST”
HTTP://WWW.YOUTUBE.COM/WATCH?V=4XPNKHJAOK8
LINUS USES HIS “CIRCLE OF TRUST”
HTTP://WWW.YOUTUBE.COM/WATCH?V=4XPNKHJAOK8
LINUS USES HIS “CIRCLE OF TRUST”
HTTP://WWW.YOUTUBE.COM/WATCH?V=4XPNKHJAOK8
GitHub
https://github.com/
Social coding with Git
GitHub is one of
Git’s Killer Features
THIS IS CALLED “FORKING”
THIS IS CALLED “FORKING”
DANA IS SPINNING OFF OF A COPY OF GENES WE WILL EDIT SEPARATELY
“Hardcore Forking Action”
CREATING A GITHUB REPOSITORY IS TRIVIAL
PUBLIC, OPEN SOURCE REPOSITORIES ARE FREE!
CREATING A GITHUB REPOSITORY IS TRIVIAL
PUBLIC, OPEN SOURCE REPOSITORIES ARE FREE!
A REPOSITORY ON GITHUB: THE RAILS SOURCE
HERE YOU CAN BROWSE OR FORK THE CODE
A REPOSITORY ON GITHUB: THE RAILS SOURCE
HERE YOU CAN BROWSE OR FORK THE CODE
A REPOSITORY ON GITHUB: THE RAILS SOURCE
HERE YOU CAN BROWSE OR FORK THE CODE
A REPOSITORY ON GITHUB: THE RAILS SOURCE
HERE YOU CAN BROWSE OR FORK THE CODE
A REPOSITORY ON GITHUB: THE RAILS SOURCE
HERE YOU CAN BROWSE OR FORK THE CODE
A FORKED REPOSITORY: RIOT
THIS FORK IS LINKED BACK TO THE ORIGINAL AND THEY CAN PULL FROM IT
A FORKED REPOSITORY: RIOT
THIS FORK IS LINKED BACK TO THE ORIGINAL AND THEY CAN PULL FROM IT
A FORKED REPOSITORY: RIOT
THIS FORK IS LINKED BACK TO THE ORIGINAL AND THEY CAN PULL FROM IT
A FORKED REPOSITORY: RIOT
THIS FORK IS LINKED BACK TO THE ORIGINAL AND THEY CAN PULL FROM IT
A FORKED REPOSITORY: RIOT
THIS FORK IS LINKED BACK TO THE ORIGINAL AND THEY CAN PULL FROM IT
THE NETWORK GRAPH
THIS IS WHERE YOU CAN SEE HOW ALL OF THE FORKS RELATE
THE NETWORK GRAPH
THIS IS WHERE YOU CAN SEE HOW ALL OF THE FORKS RELATE
THE NETWORK GRAPH
THIS IS WHERE YOU CAN SEE HOW ALL OF THE FORKS RELATE
THE NETWORK GRAPH
THIS IS WHERE YOU CAN SEE HOW ALL OF THE FORKS RELATE
THE FORK QUEUE CAN MERGE EXTERNAL CHANGES
I PREFER TO HANDLE THIS REMOTES SO A CAN WORK WITH NORMAL BRANCHES
THE FORK QUEUE CAN MERGE EXTERNAL CHANGES
I PREFER TO HANDLE THIS REMOTES SO A CAN WORK WITH NORMAL BRANCHES
THE FORK QUEUE CAN MERGE EXTERNAL CHANGES
I PREFER TO HANDLE THIS REMOTES SO A CAN WORK WITH NORMAL BRANCHES
MY FORK AND THE OFFICIAL
GIT’S REMOTES CAN MANAGE ANY NUMBER OF RELATED REPOSITORIES
MY FORK AND THE OFFICIAL
GIT’S REMOTES CAN MANAGE ANY NUMBER OF RELATED REPOSITORIES
MY FORK AND THE OFFICIAL
GIT’S REMOTES CAN MANAGE ANY NUMBER OF RELATED REPOSITORIES
MY FORK AND THE OFFICIAL
GIT’S REMOTES CAN MANAGE ANY NUMBER OF RELATED REPOSITORIES
FETCHING A REMOTE
GIT FETCH ALLOWS YOU TO ADD ALL DETAILS OF A REMOTE TO YOUR LOCAL COPY
FETCHING A REMOTE
GIT FETCH ALLOWS YOU TO ADD ALL DETAILS OF A REMOTE TO YOUR LOCAL COPY
PLAY WITH CODE FROM A REMOTE
LOCAL BRANCHES CAN TRACK REMOTE BRANCHES
PLAY WITH CODE FROM A REMOTE
LOCAL BRANCHES CAN TRACK REMOTE BRANCHES
PLAY WITH CODE FROM A REMOTE
LOCAL BRANCHES CAN TRACK REMOTE BRANCHES
FULLY SHARE WITH COLLABORATORS
A COLLABORATOR CAN USE THE CODE LIKE YOU WITHOUT PULL REQUESTS
FULLY SHARE WITH COLLABORATORS
A COLLABORATOR CAN USE THE CODE LIKE YOU WITHOUT PULL REQUESTS
FULLY SHARE WITH COLLABORATORS
A COLLABORATOR CAN USE THE CODE LIKE YOU WITHOUT PULL REQUESTS
Gists
OUR NEIGHBOR’S YARD
OUR NEIGHBOR’S YARD
SOME THINGS ARE TOO GOOD NOT TO SHARE
A GIT-CENTRIC CODE PASTING SERVICE
PASTE ONE OR MORE FILES TAGGED WITH A LANGUAGE
A GIT-CENTRIC CODE PASTING SERVICE
PASTE ONE OR MORE FILES TAGGED WITH A LANGUAGE
A GIT-CENTRIC CODE PASTING SERVICE
PASTE ONE OR MORE FILES TAGGED WITH A LANGUAGE
A GIT-CENTRIC CODE PASTING SERVICE
PASTE ONE OR MORE FILES TAGGED WITH A LANGUAGE
IT’S A PASTE AND A GIT REPOSITORY
YOU CAN FORK THIS CODE OR CLONE IT TO WORK WITH LOCALLY
IT’S A PASTE AND A GIT REPOSITORY
YOU CAN FORK THIS CODE OR CLONE IT TO WORK WITH LOCALLY
Hooks
IT’S ALWAYS GOOD TO HAVE TRAINED HELP
IT’S ALWAYS GOOD TO HAVE TRAINED HELP
IT’S ALWAYS GOOD TO HAVE TRAINED HELP
YOU CAN TEACH GIT AND GITHUB NEW TRICKS
GIT HOOKS
THE POST-COMMIT HOOK CAN BE USED TO AUTO TAG RELEASES
GIT HOOKS
THE POST-COMMIT HOOK CAN BE USED TO AUTO TAG RELEASES
GIT HOOKS
THE POST-COMMIT HOOK CAN BE USED TO AUTO TAG RELEASES
GITHUB SUPPORTS HOOKS
POST TO A URL, SEND AN EMAIL, OR MORE WHEN GITHUB IS PUSHED TO
GITHUB SUPPORTS HOOKS
POST TO A URL, SEND AN EMAIL, OR MORE WHEN GITHUB IS PUSHED TO
GITHUB SUPPORTS HOOKS
POST TO A URL, SEND AN EMAIL, OR MORE WHEN GITHUB IS PUSHED TO
GITHUB SUPPORTS HOOKS
POST TO A URL, SEND AN EMAIL, OR MORE WHEN GITHUB IS PUSHED TO
README Formatting
FIRST IMPRESSIONS MATTER
FIRST IMPRESSIONS MATTER
FIRST IMPRESSIONS MATTER
FIRST IMPRESSIONS MATTER
YOU HAVE TO ADVERTISE WHAT’S INSIDE
GITHUB IS SMART ABOUT README FORMATS
IT WILL SHOW README FILES IN EACH FOLDER AND HTMLIFY SOME CONTENT TYPES
GITHUB IS SMART ABOUT README FORMATS
IT WILL SHOW README FILES IN EACH FOLDER AND HTMLIFY SOME CONTENT TYPES
GITHUB IS SMART ABOUT README FORMATS
IT WILL SHOW README FILES IN EACH FOLDER AND HTMLIFY SOME CONTENT TYPES
Supported Formats
Supported Formats
RDoc (.rdoc)
Supported Formats
RDoc (.rdoc)

  Reuse your Ruby project documentation
Supported Formats
RDoc (.rdoc)

  Reuse your Ruby project documentation

Markdown (.markdown, .md, .mdown, …)
Supported Formats
RDoc (.rdoc)

  Reuse your Ruby project documentation

Markdown (.markdown, .md, .mdown, …)

  A human-readable format for other projects
Supported Formats
RDoc (.rdoc)

  Reuse your Ruby project documentation

Markdown (.markdown, .md, .mdown, …)

  A human-readable format for other projects

Also supported: Textile (.textile), PNG (.png),
reStructuredText (.rst), and POD (.pod)
GitHub Pages
OUR NEW OK.RB WEBSITE: HTTP://OK-RUBY.ORG/
OUR NEW OK.RB WEBSITE: HTTP://OK-RUBY.ORG/
OUR NEW OK.RB WEBSITE: HTTP://OK-RUBY.ORG/
YOU CAN HELP MAKE THIS BETTER
IT’S A PROJECT ON GITHUB
THE GITHUB PAGES FEATURE TURNS THIS INTO A REAL SITE
IT’S A PROJECT ON GITHUB
THE GITHUB PAGES FEATURE TURNS THIS INTO A REAL SITE
GitHub Pages
GitHub Pages
Name a repository after you: USER.github.com
GitHub Pages
Name a repository after you: USER.github.com

  Or add a gh-pages branch to any repository
GitHub Pages
Name a repository after you: USER.github.com

  Or add a gh-pages branch to any repository

GitHub will build the site after each commit
GitHub Pages
Name a repository after you: USER.github.com

  Or add a gh-pages branch to any repository

GitHub will build the site after each commit

Sites are Jekyll (a static site generator) processed
GitHub Pages
Name a repository after you: USER.github.com

  Or add a gh-pages branch to any repository

GitHub will build the site after each commit

Sites are Jekyll (a static site generator) processed

  Used to build listings, syntax highlight, etc.
GitHub Pages
Name a repository after you: USER.github.com

  Or add a gh-pages branch to any repository

GitHub will build the site after each commit

Sites are Jekyll (a static site generator) processed

  Used to build listings, syntax highlight, etc.

You can point a real domain at them
Documentation
Learning more about Git and GitHub
IF YOU FELL ASLEEP IN THIS TALK…
IF YOU FELL ASLEEP IN THIS TALK…
YOU MAY NEED TO RTFM
Where to Find the Docs
Where to Find the Docs
Git has awesome man(ual) pages
Where to Find the Docs
Git has awesome man(ual) pages

 Replace spaces with dashes: man git-stash
Where to Find the Docs
Git has awesome man(ual) pages

  Replace spaces with dashes: man git-stash

Scott Chacon’s (GitHub’s Git Guru) Pro Git book
Where to Find the Docs
Git has awesome man(ual) pages

  Replace spaces with dashes: man git-stash

Scott Chacon’s (GitHub’s Git Guru) Pro Git book

  Free online: http://progit.org/
Where to Find the Docs
Git has awesome man(ual) pages

  Replace spaces with dashes: man git-stash

Scott Chacon’s (GitHub’s Git Guru) Pro Git book

  Free online: http://progit.org/

GitHub has good guides: http://help.github.com/
Where to Find the Docs
Git has awesome man(ual) pages

  Replace spaces with dashes: man git-stash

Scott Chacon’s (GitHub’s Git Guru) Pro Git book

  Free online: http://progit.org/

GitHub has good guides: http://help.github.com/

  They cover GitHub and Git topics
You have passed
this endurance test!

More Related Content

What's hot

Intro to git and git hub
Intro to git and git hubIntro to git and git hub
Intro to git and git hubVenkat Malladi
 
Git - Basic Crash Course
Git - Basic Crash CourseGit - Basic Crash Course
Git - Basic Crash CourseNilay Binjola
 
Git - An Introduction
Git - An IntroductionGit - An Introduction
Git - An IntroductionBehzad Altaf
 
Git One Day Training Notes
Git One Day Training NotesGit One Day Training Notes
Git One Day Training Notesglen_a_smith
 
Git and Github slides.pdf
Git and Github slides.pdfGit and Github slides.pdf
Git and Github slides.pdfTilton2
 
Introduction to GitHub
Introduction to GitHubIntroduction to GitHub
Introduction to GitHubNishan Bose
 
Git Terminologies
Git TerminologiesGit Terminologies
Git TerminologiesYash
 
Introducing GitLab (June 2018)
Introducing GitLab (June 2018)Introducing GitLab (June 2018)
Introducing GitLab (June 2018)Noa Harel
 
The everyday developer's guide to version control with Git
The everyday developer's guide to version control with GitThe everyday developer's guide to version control with Git
The everyday developer's guide to version control with GitE Carter
 
Git and GitHub for Documentation
Git and GitHub for DocumentationGit and GitHub for Documentation
Git and GitHub for DocumentationAnne Gentle
 
Git flow Introduction
Git flow IntroductionGit flow Introduction
Git flow IntroductionDavid Paluy
 
Git and GitHub | Concept about Git and GitHub Process | Git Process overview
Git and GitHub | Concept about Git and GitHub Process | Git Process overviewGit and GitHub | Concept about Git and GitHub Process | Git Process overview
Git and GitHub | Concept about Git and GitHub Process | Git Process overviewRueful Robin
 
A Practical Introduction to git
A Practical Introduction to gitA Practical Introduction to git
A Practical Introduction to gitEmanuele Olivetti
 

What's hot (20)

Intro to git and git hub
Intro to git and git hubIntro to git and git hub
Intro to git and git hub
 
Git - Basic Crash Course
Git - Basic Crash CourseGit - Basic Crash Course
Git - Basic Crash Course
 
Git - An Introduction
Git - An IntroductionGit - An Introduction
Git - An Introduction
 
Git real slides
Git real slidesGit real slides
Git real slides
 
Git and GitHub
Git and GitHubGit and GitHub
Git and GitHub
 
Git One Day Training Notes
Git One Day Training NotesGit One Day Training Notes
Git One Day Training Notes
 
Git and Github
Git and GithubGit and Github
Git and Github
 
Git and Github slides.pdf
Git and Github slides.pdfGit and Github slides.pdf
Git and Github slides.pdf
 
Introduction to GitHub
Introduction to GitHubIntroduction to GitHub
Introduction to GitHub
 
Git Terminologies
Git TerminologiesGit Terminologies
Git Terminologies
 
Git basic
Git basicGit basic
Git basic
 
Introducing GitLab (June 2018)
Introducing GitLab (June 2018)Introducing GitLab (June 2018)
Introducing GitLab (June 2018)
 
The everyday developer's guide to version control with Git
The everyday developer's guide to version control with GitThe everyday developer's guide to version control with Git
The everyday developer's guide to version control with Git
 
Git n git hub
Git n git hubGit n git hub
Git n git hub
 
Git and GitHub for Documentation
Git and GitHub for DocumentationGit and GitHub for Documentation
Git and GitHub for Documentation
 
Git flow Introduction
Git flow IntroductionGit flow Introduction
Git flow Introduction
 
Git and GitHub | Concept about Git and GitHub Process | Git Process overview
Git and GitHub | Concept about Git and GitHub Process | Git Process overviewGit and GitHub | Concept about Git and GitHub Process | Git Process overview
Git and GitHub | Concept about Git and GitHub Process | Git Process overview
 
Basic Git Intro
Basic Git IntroBasic Git Intro
Basic Git Intro
 
A Practical Introduction to git
A Practical Introduction to gitA Practical Introduction to git
A Practical Introduction to git
 
Introduction git
Introduction gitIntroduction git
Introduction git
 

Viewers also liked

Git 101: Git and GitHub for Beginners
Git 101: Git and GitHub for Beginners Git 101: Git and GitHub for Beginners
Git 101: Git and GitHub for Beginners HubSpot
 
Introduction to Git/Github - A beginner's guide
Introduction to Git/Github - A beginner's guideIntroduction to Git/Github - A beginner's guide
Introduction to Git/Github - A beginner's guideRohit Arora
 
Getting Git Right
Getting Git RightGetting Git Right
Getting Git RightSven Peters
 
Advanced Git
Advanced GitAdvanced Git
Advanced Gitsegv
 
Control de versiones con Git y Github
Control de versiones con Git y GithubControl de versiones con Git y Github
Control de versiones con Git y Githubguest638090
 
Git in a nutshell
Git in a nutshellGit in a nutshell
Git in a nutshellNelson Tai
 
Git 101 Presentation
Git 101 PresentationGit 101 Presentation
Git 101 PresentationScott Chacon
 
[NDC16] Effective Git
[NDC16] Effective Git[NDC16] Effective Git
[NDC16] Effective GitChanwoong Kim
 
Git 101 - Crash Course in Version Control using Git
Git 101 - Crash Course in Version Control using GitGit 101 - Crash Course in Version Control using Git
Git 101 - Crash Course in Version Control using GitGeoff Hoffman
 
Quick Introduction to git
Quick Introduction to gitQuick Introduction to git
Quick Introduction to gitJoel Krebs
 
GitHub for People Who Don't Code
GitHub for People Who Don't CodeGitHub for People Who Don't Code
GitHub for People Who Don't CodeChristopher Schmitt
 
VNPAY Git Seminar
VNPAY Git SeminarVNPAY Git Seminar
VNPAY Git SeminarMr Slowly
 
GitHub Talk - Cody Carnachan
GitHub Talk - Cody CarnachanGitHub Talk - Cody Carnachan
GitHub Talk - Cody CarnachanCody Carnachan
 

Viewers also liked (20)

Getting Git
Getting GitGetting Git
Getting Git
 
Git 101: Git and GitHub for Beginners
Git 101: Git and GitHub for Beginners Git 101: Git and GitHub for Beginners
Git 101: Git and GitHub for Beginners
 
Introduction to Git and GitHub
Introduction to Git and GitHubIntroduction to Git and GitHub
Introduction to Git and GitHub
 
Introduction to Git/Github - A beginner's guide
Introduction to Git/Github - A beginner's guideIntroduction to Git/Github - A beginner's guide
Introduction to Git/Github - A beginner's guide
 
Git Tutorial 教學
Git Tutorial 教學Git Tutorial 教學
Git Tutorial 教學
 
Getting Git Right
Getting Git RightGetting Git Right
Getting Git Right
 
Advanced Git
Advanced GitAdvanced Git
Advanced Git
 
Inside GitHub with Chris Wanstrath
Inside GitHub with Chris WanstrathInside GitHub with Chris Wanstrath
Inside GitHub with Chris Wanstrath
 
Control de versiones con Git y Github
Control de versiones con Git y GithubControl de versiones con Git y Github
Control de versiones con Git y Github
 
Git in a nutshell
Git in a nutshellGit in a nutshell
Git in a nutshell
 
Git 101 Presentation
Git 101 PresentationGit 101 Presentation
Git 101 Presentation
 
[NDC16] Effective Git
[NDC16] Effective Git[NDC16] Effective Git
[NDC16] Effective Git
 
Introduction to git
Introduction to gitIntroduction to git
Introduction to git
 
Github basics
Github basicsGithub basics
Github basics
 
Git 101 - Crash Course in Version Control using Git
Git 101 - Crash Course in Version Control using GitGit 101 - Crash Course in Version Control using Git
Git 101 - Crash Course in Version Control using Git
 
Git Branching Model
Git Branching ModelGit Branching Model
Git Branching Model
 
Quick Introduction to git
Quick Introduction to gitQuick Introduction to git
Quick Introduction to git
 
GitHub for People Who Don't Code
GitHub for People Who Don't CodeGitHub for People Who Don't Code
GitHub for People Who Don't Code
 
VNPAY Git Seminar
VNPAY Git SeminarVNPAY Git Seminar
VNPAY Git Seminar
 
GitHub Talk - Cody Carnachan
GitHub Talk - Cody CarnachanGitHub Talk - Cody Carnachan
GitHub Talk - Cody Carnachan
 

Similar to Git and GitHub

Git cheat-sheets
Git cheat-sheetsGit cheat-sheets
Git cheat-sheetsozone777
 
Introduction To Git Workshop
Introduction To Git WorkshopIntroduction To Git Workshop
Introduction To Git Workshopthemystic_ca
 
Jedi Mind Tricks for Git
Jedi Mind Tricks for GitJedi Mind Tricks for Git
Jedi Mind Tricks for GitJan Krag
 
Git Distributed Version Control System
Git   Distributed Version Control SystemGit   Distributed Version Control System
Git Distributed Version Control SystemVictor Wong
 
Git Aliases of the Gods!
Git Aliases of the Gods!Git Aliases of the Gods!
Git Aliases of the Gods!Atlassian
 
Git session day 2
Git session day 2Git session day 2
Git session day 2Mosaab Ehab
 
SECON'2017, Цаль-Цалко Иван, Go на практике
SECON'2017, Цаль-Цалко Иван, Go на практикеSECON'2017, Цаль-Цалко Иван, Go на практике
SECON'2017, Цаль-Цалко Иван, Go на практикеSECON
 
Git for beginners
Git for beginnersGit for beginners
Git for beginnersVinh Nguyen
 
Git Started With Git
Git Started With GitGit Started With Git
Git Started With GitNick Quaranto
 
Introducción a git y GitHub
Introducción a git y GitHubIntroducción a git y GitHub
Introducción a git y GitHubLucas Videla
 
Git Memento of basic commands
Git Memento of basic commandsGit Memento of basic commands
Git Memento of basic commandsZakaria Bouazza
 

Similar to Git and GitHub (20)

T3dd10 git
T3dd10 gitT3dd10 git
T3dd10 git
 
Git cheat-sheets
Git cheat-sheetsGit cheat-sheets
Git cheat-sheets
 
Introduction To Git Workshop
Introduction To Git WorkshopIntroduction To Git Workshop
Introduction To Git Workshop
 
Becoming a Git Master
Becoming a Git MasterBecoming a Git Master
Becoming a Git Master
 
Wokshop de Git
Wokshop de Git Wokshop de Git
Wokshop de Git
 
Jedi Mind Tricks for Git
Jedi Mind Tricks for GitJedi Mind Tricks for Git
Jedi Mind Tricks for Git
 
Git Distributed Version Control System
Git   Distributed Version Control SystemGit   Distributed Version Control System
Git Distributed Version Control System
 
Jedi Mind Tricks in Git
Jedi Mind Tricks in GitJedi Mind Tricks in Git
Jedi Mind Tricks in Git
 
Git and Unity
Git and UnityGit and Unity
Git and Unity
 
Loading...git
Loading...gitLoading...git
Loading...git
 
Working with Git
Working with GitWorking with Git
Working with Git
 
git session --interactive
git session --interactivegit session --interactive
git session --interactive
 
Git Aliases of the Gods!
Git Aliases of the Gods!Git Aliases of the Gods!
Git Aliases of the Gods!
 
Git session day 2
Git session day 2Git session day 2
Git session day 2
 
SECON'2017, Цаль-Цалко Иван, Go на практике
SECON'2017, Цаль-Цалко Иван, Go на практикеSECON'2017, Цаль-Цалко Иван, Go на практике
SECON'2017, Цаль-Цалко Иван, Go на практике
 
Git, A Primer
Git, A PrimerGit, A Primer
Git, A Primer
 
Git for beginners
Git for beginnersGit for beginners
Git for beginners
 
Git Started With Git
Git Started With GitGit Started With Git
Git Started With Git
 
Introducción a git y GitHub
Introducción a git y GitHubIntroducción a git y GitHub
Introducción a git y GitHub
 
Git Memento of basic commands
Git Memento of basic commandsGit Memento of basic commands
Git Memento of basic commands
 

More from James Gray

A Dickens of A Keynote
A Dickens of A KeynoteA Dickens of A Keynote
A Dickens of A KeynoteJames Gray
 
Regular expressions
Regular expressionsRegular expressions
Regular expressionsJames Gray
 
Counting on God
Counting on GodCounting on God
Counting on GodJames Gray
 
In the Back of Your Mind
In the Back of Your MindIn the Back of Your Mind
In the Back of Your MindJames Gray
 
Amazon's Simple Storage Service (S3)
Amazon's Simple Storage Service (S3)Amazon's Simple Storage Service (S3)
Amazon's Simple Storage Service (S3)James Gray
 
Test Coverage in Rails
Test Coverage in RailsTest Coverage in Rails
Test Coverage in RailsJames Gray
 
Rails Routing And Rendering
Rails Routing And RenderingRails Routing And Rendering
Rails Routing And RenderingJames Gray
 
Sending Email with Rails
Sending Email with RailsSending Email with Rails
Sending Email with RailsJames Gray
 
Associations in Rails
Associations in RailsAssociations in Rails
Associations in RailsJames Gray
 
DRYing Up Rails Views and Controllers
DRYing Up Rails Views and ControllersDRYing Up Rails Views and Controllers
DRYing Up Rails Views and ControllersJames Gray
 
Building a Rails Interface
Building a Rails InterfaceBuilding a Rails Interface
Building a Rails InterfaceJames Gray
 
Rails Model Basics
Rails Model BasicsRails Model Basics
Rails Model BasicsJames Gray
 
Wed Development on Rails
Wed Development on RailsWed Development on Rails
Wed Development on RailsJames Gray
 

More from James Gray (18)

A Dickens of A Keynote
A Dickens of A KeynoteA Dickens of A Keynote
A Dickens of A Keynote
 
I Doubt That!
I Doubt That!I Doubt That!
I Doubt That!
 
Regular expressions
Regular expressionsRegular expressions
Regular expressions
 
Counting on God
Counting on GodCounting on God
Counting on God
 
In the Back of Your Mind
In the Back of Your MindIn the Back of Your Mind
In the Back of Your Mind
 
Unblocked
UnblockedUnblocked
Unblocked
 
Module Magic
Module MagicModule Magic
Module Magic
 
API Design
API DesignAPI Design
API Design
 
Amazon's Simple Storage Service (S3)
Amazon's Simple Storage Service (S3)Amazon's Simple Storage Service (S3)
Amazon's Simple Storage Service (S3)
 
Test Coverage in Rails
Test Coverage in RailsTest Coverage in Rails
Test Coverage in Rails
 
Rails Routing And Rendering
Rails Routing And RenderingRails Routing And Rendering
Rails Routing And Rendering
 
Sending Email with Rails
Sending Email with RailsSending Email with Rails
Sending Email with Rails
 
Associations in Rails
Associations in RailsAssociations in Rails
Associations in Rails
 
DRYing Up Rails Views and Controllers
DRYing Up Rails Views and ControllersDRYing Up Rails Views and Controllers
DRYing Up Rails Views and Controllers
 
Building a Rails Interface
Building a Rails InterfaceBuilding a Rails Interface
Building a Rails Interface
 
Rails Model Basics
Rails Model BasicsRails Model Basics
Rails Model Basics
 
Ruby
RubyRuby
Ruby
 
Wed Development on Rails
Wed Development on RailsWed Development on Rails
Wed Development on Rails
 

Recently uploaded

AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxnull - The Open Security Community
 
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsSnow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsHyundai Motor Group
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 

Recently uploaded (20)

AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
 
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsSnow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 

Git and GitHub

  • 1. Git and GitHub The unabridged story
  • 2. BUT FIRST A WORD FROM OUR SPONSOR
  • 3. BUT FIRST A WORD FROM OUR SPONSOR
  • 4. BUT FIRST A WORD FROM OUR SPONSOR HAPPY BIRTHDAY DANA!
  • 6. What is Git, really?
  • 8. Intelligence Check Subversion is a smart database of file differences
  • 9. Intelligence Check Subversion is a smart database of file differences Unfortunately, this makes it quite complex
  • 10. Intelligence Check Subversion is a smart database of file differences Unfortunately, this makes it quite complex Git is pretty stupid
  • 11. Intelligence Check Subversion is a smart database of file differences Unfortunately, this makes it quite complex Git is pretty stupid Stores trees of content, much like a file system
  • 12. Intelligence Check Subversion is a smart database of file differences Unfortunately, this makes it quite complex Git is pretty stupid Stores trees of content, much like a file system A commit creates a new tree reachable by name
  • 13. Intelligence Check Subversion is a smart database of file differences Unfortunately, this makes it quite complex Git is pretty stupid Stores trees of content, much like a file system A commit creates a new tree reachable by name It can change your directory to recreate any tree
  • 15. Git Isn’t Really an SCM Git does Source Code Management and
  • 16. Git Isn’t Really an SCM Git does Source Code Management and Peer to peer content distribution
  • 17. Git Isn’t Really an SCM Git does Source Code Management and Peer to peer content distribution Document database
  • 18. Git Isn’t Really an SCM Git does Source Code Management and Peer to peer content distribution Document database Distributed wiki
  • 19. Git Isn’t Really an SCM Git does Source Code Management and Peer to peer content distribution Document database Distributed wiki Distributed issue tracker
  • 20. Git Isn’t Really an SCM Git does Source Code Management and Peer to peer content distribution Document database Distributed wiki Distributed issue tracker Backups
  • 21. The Plusses of a Simple Design
  • 22. The Plusses of a Simple Design It was designed to manage the development of the Linux kernel (a very large code base)
  • 23. The Plusses of a Simple Design It was designed to manage the development of the Linux kernel (a very large code base) Git is very efficient
  • 24. The Plusses of a Simple Design It was designed to manage the development of the Linux kernel (a very large code base) Git is very efficient Git handles non-linear development with grace
  • 25. The Plusses of a Simple Design It was designed to manage the development of the Linux kernel (a very large code base) Git is very efficient Git handles non-linear development with grace Git is distributed from the ground up
  • 26.
  • 27.
  • 28.
  • 29. SOMETIMES YOU HAVE A TOILET IN YOUR YARD
  • 30. SOMETIMES YOU HAVE A TOILET IN YOUR YARD AND WHO WANTS THAT, REALLY?
  • 31. The Minuses of the Toolkit Design
  • 32. The Minuses of the Toolkit Design Git provides a ton of commands to interact with it
  • 33. The Minuses of the Toolkit Design Git provides a ton of commands to interact with it The “porcelain” commands are the ones you typically interact with
  • 34. The Minuses of the Toolkit Design Git provides a ton of commands to interact with it The “porcelain” commands are the ones you typically interact with The lower-level “plumbing” commands are crazy powerful, but less user friendly
  • 35. The Minuses of the Toolkit Design Git provides a ton of commands to interact with it The “porcelain” commands are the ones you typically interact with The lower-level “plumbing” commands are crazy powerful, but less user friendly This can add up to make Git a little intimidating
  • 37. IF YOU BUILD IT, THEY WILL COME
  • 38. IF YOU BUILD IT, THEY WILL COME
  • 39. IF YOU BUILD IT, THEY WILL COME SOMETIMES YOU JUST HAVE TO INSTALL A RIDICULOUS ROBOT
  • 40. OFFICIAL SITE: HTTP://GIT-SCM.COM/ THERE ARE BINARIES FOR SOME PLATFORMS
  • 41. OFFICIAL SITE: HTTP://GIT-SCM.COM/ THERE ARE BINARIES FOR SOME PLATFORMS
  • 42. OFFICIAL SITE: HTTP://GIT-SCM.COM/ THERE ARE BINARIES FOR SOME PLATFORMS
  • 43. THE INSTRUCTIONS I USE TO BUILD ON MAC OS X THESE SIDESTEP THE DOCUMENTATION AND MACPORTS REQUIREMENTS
  • 44. THE INSTRUCTIONS I USE TO BUILD ON MAC OS X THESE SIDESTEP THE DOCUMENTATION AND MACPORTS REQUIREMENTS
  • 45. Git is still young and growing fast (update to 1.7)
  • 46. [user] name = James Edward Gray II email = james@graysoftinc.com [apply] whitespace = nowarn [color] status = auto branch = auto interactive = auto repositoryformatversion = 0 filemode = true bare = false logallrefupdates = true [gc] auto = 1 [github] user = JEG2 token = … ~/.GITCONFIG THESE ARE SOME VERY HELPFUL GIT INTERFACE SETTINGS
  • 47. [user] name = James Edward Gray II email = james@graysoftinc.com [apply] whitespace = nowarn [color] status = auto branch = auto interactive = auto repositoryformatversion = 0 filemode = true bare = false logallrefupdates = true [gc] auto = 1 [github] user = JEG2 token = … ~/.GITCONFIG THESE ARE SOME VERY HELPFUL GIT INTERFACE SETTINGS
  • 48. [user] name = James Edward Gray II email = james@graysoftinc.com [apply] whitespace = nowarn [color] status = auto branch = auto interactive = auto repositoryformatversion = 0 filemode = true bare = false logallrefupdates = true [gc] auto = 1 [github] user = JEG2 token = … ~/.GITCONFIG THESE ARE SOME VERY HELPFUL GIT INTERFACE SETTINGS
  • 49. [user] name = James Edward Gray II email = james@graysoftinc.com [apply] whitespace = nowarn [color] status = auto branch = auto interactive = auto repositoryformatversion = 0 filemode = true bare = false logallrefupdates = true [gc] auto = 1 [github] user = JEG2 token = … ~/.GITCONFIG THESE ARE SOME VERY HELPFUL GIT INTERFACE SETTINGS
  • 50. set mainfont {Monaco 12} set textfont {Monaco 12} set uifont {"Monaco Bold" 12} set tabstop 8 set findmergefiles 0 set maxgraphpct 50 set maxwidth 16 set cmitmode patch set wrapcomment none set showneartags 1 set showlocalchanges 1 set datetimeformat {%Y-%m-%d %H:%M:%S} set limitdiffs 1 set bgcolor white set fgcolor black set colors {green red blue magenta darkgrey brown orange} set diffcolors {red "#00a000" blue} set diffcontext 3 set selectbgcolor gray85 set geometry(main) 794x484+5+45 set geometry(topwidth) 790 set geometry(topheight) 150 set geometry(pwsash0) "280 2" set geometry(pwsash1) "420 2" set geometry(botwidth) 350 set geometry(botheight) 314 set permviews {} ~/.GITK THESE SETTINGS CLEAN UP THE INCLUDED GUI
  • 51. # Git alias g="git status" alias ga="git add" alias gaa="git add ." alias gc="git commit -m" alias gca="git commit -am" alias gb="git branch" alias gbd="git branch -d" alias gco="git checkout" alias gcob="git checkout -b" alias gm="git merge" alias gr="git rebase" alias gl="git log" alias gs="git show" alias gd="git diff" alias gbl="git blame" alias gps="git push" alias gpl="git pull" ~/.BASHRC THESE ARE SOME BASH ALIASES I USE
  • 52. # Git alias g="git status" alias ga="git add" alias gaa="git add ." alias gc="git commit -m" alias gca="git commit -am" alias gb="git branch" alias gbd="git branch -d" alias gco="git checkout" alias gcob="git checkout -b" alias gm="git merge" alias gr="git rebase" alias gl="git log" alias gs="git show" alias gd="git diff" alias gbl="git blame" alias gps="git push" alias gpl="git pull" ~/.BASHRC THESE ARE SOME BASH ALIASES I USE
  • 53. # Git alias g="git status" alias ga="git add" alias gaa="git add ." alias gc="git commit -m" alias gca="git commit -am" alias gb="git branch" alias gbd="git branch -d" alias gco="git checkout" alias gcob="git checkout -b" alias gm="git merge" alias gr="git rebase" alias gl="git log" alias gs="git show" alias gd="git diff" alias gbl="git blame" alias gps="git push" alias gpl="git pull" ~/.BASHRC THESE ARE SOME BASH ALIASES I USE
  • 55. Memorize all of That? There’s a new trend to store your “dotfiles” online
  • 56. Memorize all of That? There’s a new trend to store your “dotfiles” online This makes it easy to move them
  • 57. Memorize all of That? There’s a new trend to store your “dotfiles” online This makes it easy to move them Plus we can all share
  • 58. Memorize all of That? There’s a new trend to store your “dotfiles” online This makes it easy to move them Plus we can all share Surprise: A great place to find these is GitHub
  • 59. Memorize all of That? There’s a new trend to store your “dotfiles” online This makes it easy to move them Plus we can all share Surprise: A great place to find these is GitHub Mine are at: http://github.com/JEG2/dotfiles
  • 63. DANA IS SAD HER CRAFT ROOM IS TRANSITIONING INTO A NURSERY
  • 64. STAGING A CHANGE, THEN COMMITTING THIS IS A NORMAL WORKFLOW FOR CHANGES IN GIT
  • 65. GIT STATUS GIT ADD . GIT STATUS GIT COMMIT -M “FIRST COMMIT.” STAGING A CHANGE, THEN COMMITTING THIS IS A NORMAL WORKFLOW FOR CHANGES IN GIT
  • 66. GIT STATUS GIT ADD . GIT STATUS GIT COMMIT -M “FIRST COMMIT.” STAGING A CHANGE, THEN COMMITTING THIS IS A NORMAL WORKFLOW FOR CHANGES IN GIT
  • 67. GIT STATUS GIT ADD . GIT STATUS GIT COMMIT -M “FIRST COMMIT.” STAGING A CHANGE, THEN COMMITTING THIS IS A NORMAL WORKFLOW FOR CHANGES IN GIT
  • 68. GIT STATUS GIT ADD . GIT STATUS GIT COMMIT -M “FIRST COMMIT.” STAGING A CHANGE, THEN COMMITTING THIS IS A NORMAL WORKFLOW FOR CHANGES IN GIT
  • 69. GIT STATUS GIT ADD . GIT STATUS GIT COMMIT -M “FIRST COMMIT.” STAGING A CHANGE, THEN COMMITTING THIS IS A NORMAL WORKFLOW FOR CHANGES IN GIT
  • 70. GIT DATA IS SHARED BY THREE AREAS THE REPOSITORY HOLDS ALL POSSIBLE WORKING DIRECTORIES
  • 71. THE WORKING DIRECTORY GIT DATA IS SHARED BY THREE AREAS THE REPOSITORY HOLDS ALL POSSIBLE WORKING DIRECTORIES
  • 72. THE INDEX OR STAGING AREA GIT DATA IS SHARED BY THREE AREAS THE REPOSITORY HOLDS ALL POSSIBLE WORKING DIRECTORIES
  • 73. THE REPOSITORY GIT DATA IS SHARED BY THREE AREAS THE REPOSITORY HOLDS ALL POSSIBLE WORKING DIRECTORIES
  • 74. GIT INCLUDES POWERFUL INSPECTION TOOLS A SHA1 HASH (40 CHARACTERS) IS HOW GIT NAMES EVERYTHING
  • 75. GIT LOG GIT SHOW 96987 GIT SHOW 5F3F6 GIT BLAME README GIT INCLUDES POWERFUL INSPECTION TOOLS A SHA1 HASH (40 CHARACTERS) IS HOW GIT NAMES EVERYTHING
  • 76. GIT LOG GIT SHOW 96987 GIT SHOW 5F3F6 GIT BLAME README GIT INCLUDES POWERFUL INSPECTION TOOLS A SHA1 HASH (40 CHARACTERS) IS HOW GIT NAMES EVERYTHING
  • 77. GIT LOG GIT SHOW 96987 GIT SHOW 5F3F6 GIT BLAME README GIT INCLUDES POWERFUL INSPECTION TOOLS A SHA1 HASH (40 CHARACTERS) IS HOW GIT NAMES EVERYTHING
  • 78. GIT LOG GIT SHOW 96987 GIT SHOW 5F3F6 GIT BLAME README GIT INCLUDES POWERFUL INSPECTION TOOLS A SHA1 HASH (40 CHARACTERS) IS HOW GIT NAMES EVERYTHING
  • 79. GIT LOG GIT SHOW 96987 GIT SHOW 5F3F6 GIT BLAME README GIT INCLUDES POWERFUL INSPECTION TOOLS A SHA1 HASH (40 CHARACTERS) IS HOW GIT NAMES EVERYTHING
  • 80. GIT LOG GIT SHOW 96987 GIT SHOW 5F3F6 GIT BLAME README GIT INCLUDES POWERFUL INSPECTION TOOLS A SHA1 HASH (40 CHARACTERS) IS HOW GIT NAMES EVERYTHING
  • 82. YOU CAN ADD BRANCHES TO ANYTHING
  • 83. YOU CAN ADD BRANCHES TO ANYTHING
  • 84. YOU CAN ADD BRANCHES TO ANYTHING A KID, YOUR SOURCE CODE, OR WHATEVER
  • 85.
  • 86. Using Git without branches is like buying condoms and not having any sex
  • 87. GIT WAS MADE TO BRANCH, LITERALLY! WHEN YOU BRANCH, GIT HAS TO WRITE 40 CHARACTERS TO A FILE (SUPER CHEAP)!
  • 88. GIT WAS MADE TO BRANCH, LITERALLY! WHEN YOU BRANCH, GIT HAS TO WRITE 40 CHARACTERS TO A FILE (SUPER CHEAP)!
  • 89. GIT WAS MADE TO BRANCH, LITERALLY! WHEN YOU BRANCH, GIT HAS TO WRITE 40 CHARACTERS TO A FILE (SUPER CHEAP)!
  • 90. GIT WAS MADE TO BRANCH, LITERALLY! WHEN YOU BRANCH, GIT HAS TO WRITE 40 CHARACTERS TO A FILE (SUPER CHEAP)!
  • 91. THE INCLUDED GITK SHOWS BRANCHES PASS THE --ALL FLAG TO SEE BRANCHES YOU AREN’T CURRENTLY ON
  • 92. THE INCLUDED GITK SHOWS BRANCHES PASS THE --ALL FLAG TO SEE BRANCHES YOU AREN’T CURRENTLY ON
  • 93. GIT MERGE PULLS THE NAMED BRANCH IN UNLIKE SUBVERSION, GIT MERGE IS POWERFUL, SMART, AND EASY TO USE
  • 94. GIT MERGE PULLS THE NAMED BRANCH IN UNLIKE SUBVERSION, GIT MERGE IS POWERFUL, SMART, AND EASY TO USE
  • 95. GIT MERGE PULLS THE NAMED BRANCH IN UNLIKE SUBVERSION, GIT MERGE IS POWERFUL, SMART, AND EASY TO USE
  • 96. GIT MERGE PULLS THE NAMED BRANCH IN UNLIKE SUBVERSION, GIT MERGE IS POWERFUL, SMART, AND EASY TO USE
  • 97. THE HISTORY SHOWS THE INCORPORATED BRANCH EVEN AFTER THE BRANCH IS DELETED, GIT REMEMBERS WHERE IT CAME FROM
  • 98. THE HISTORY SHOWS THE INCORPORATED BRANCH EVEN AFTER THE BRANCH IS DELETED, GIT REMEMBERS WHERE IT CAME FROM
  • 99. THE HISTORY SHOWS THE INCORPORATED BRANCH EVEN AFTER THE BRANCH IS DELETED, GIT REMEMBERS WHERE IT CAME FROM
  • 100. THE HISTORY SHOWS THE INCORPORATED BRANCH EVEN AFTER THE BRANCH IS DELETED, GIT REMEMBERS WHERE IT CAME FROM
  • 101. REBASE CAN BE USED TO FLATTEN THE HISTORY YOU CAN CHOOSE TO ADD A BRANCH ONTO THE END OF ANOTHER BRANCH
  • 102. REBASE CAN BE USED TO FLATTEN THE HISTORY YOU CAN CHOOSE TO ADD A BRANCH ONTO THE END OF ANOTHER BRANCH
  • 103. REBASE CAN BE USED TO FLATTEN THE HISTORY YOU CAN CHOOSE TO ADD A BRANCH ONTO THE END OF ANOTHER BRANCH
  • 104. NOW THE MERGED HISTORY IS JUST A FLAT LINE GIT REPLAYED OUR CHANGES ONTO THE END OF THE MASTER BRANCH
  • 105.
  • 106. With Git, it’s never too late to branch!
  • 107. YOU CAN STILL BRANCH AFTER CHANGES IF A PROBLEM STARTS TO LOOK BIG AFTER WORKING ON IT, MOVE IT INTO A BRANCH
  • 108. YOU CAN STILL BRANCH AFTER CHANGES IF A PROBLEM STARTS TO LOOK BIG AFTER WORKING ON IT, MOVE IT INTO A BRANCH
  • 109. GIT STASH CAN HOLDS SOME CHANGES FOR LATER I USE THIS WHEN I GET INTERRUPTED AND NEED TO SWITCH GEARS
  • 110. GIT STASH CAN HOLDS SOME CHANGES FOR LATER I USE THIS WHEN I GET INTERRUPTED AND NEED TO SWITCH GEARS
  • 111. GIT STASH CAN HOLDS SOME CHANGES FOR LATER I USE THIS WHEN I GET INTERRUPTED AND NEED TO SWITCH GEARS
  • 113. DANA REVISED HER OWN HISTORY
  • 114. DANA REVISED HER OWN HISTORY
  • 115. DANA REVISED HER OWN HISTORY
  • 116. DANA REVISED HER OWN HISTORY SHE THREW OUT ABOUT 60 COMMITS… ERR, POUNDS
  • 117. Git Trusts you With the Scary Power Tools
  • 118. Git Trusts you With the Scary Power Tools Several Git commands can be used to revise the commit history
  • 119. Git Trusts you With the Scary Power Tools Several Git commands can be used to revise the commit history Total rewrites are possible
  • 120. Git Trusts you With the Scary Power Tools Several Git commands can be used to revise the commit history Total rewrites are possible Some consider this very evil
  • 121. Git Trusts you With the Scary Power Tools Several Git commands can be used to revise the commit history Total rewrites are possible Some consider this very evil Let me show you two lighter uses that I consider practical
  • 122. YOU CAN AMEND (OR ADD TO) A COMMIT THIS IS AWESOME PERFECT FOR WHEN YOU FORGET TO ADD A FILE
  • 123. YOU CAN AMEND (OR ADD TO) A COMMIT THIS IS AWESOME PERFECT FOR WHEN YOU FORGET TO ADD A FILE
  • 124. YOU GET A CHANCE TO REVISE THE MESSAGE AS YOU CAN SEE, I HAVE TEXTMATE SET AS MY EDITOR
  • 125. THE TWO COMMITS BECAME ONE NOTICE HOW ALL ASPECTS OF THE SECOND COMMIT WERE ROLLED INTO THE FIRST
  • 126. THE TWO COMMITS BECAME ONE NOTICE HOW ALL ASPECTS OF THE SECOND COMMIT WERE ROLLED INTO THE FIRST
  • 127. GIT CAN “CHERRY PICK” COMMITS YOU AREN’T REQUIRED TO TAKE COMMITS IN ORDER
  • 128. GIT CAN “CHERRY PICK” COMMITS YOU AREN’T REQUIRED TO TAKE COMMITS IN ORDER
  • 129. GIT CAN “CHERRY PICK” COMMITS YOU AREN’T REQUIRED TO TAKE COMMITS IN ORDER
  • 131. WHEELCHAIRS CAN RIDE JAPAN’S TRAINS
  • 132. WHEELCHAIRS CAN RIDE JAPAN’S TRAINS
  • 133. WHEELCHAIRS CAN RIDE JAPAN’S TRAINS BE SURE YOU SPEAK A LITTLE JAPANESE THOUGH, JUST IN CASE!
  • 135. Git Ships With Subversion Support Checkout with: git svn clone SUBVERSION_URL
  • 136. Git Ships With Subversion Support Checkout with: git svn clone SUBVERSION_URL Add --username=USER if needed
  • 137. Git Ships With Subversion Support Checkout with: git svn clone SUBVERSION_URL Add --username=USER if needed Update with: git svn rebase
  • 138. Git Ships With Subversion Support Checkout with: git svn clone SUBVERSION_URL Add --username=USER if needed Update with: git svn rebase Subversion requires a linear history, thus rebase
  • 139. Git Ships With Subversion Support Checkout with: git svn clone SUBVERSION_URL Add --username=USER if needed Update with: git svn rebase Subversion requires a linear history, thus rebase Use Git to develop locally as normal
  • 140. Git Ships With Subversion Support Checkout with: git svn clone SUBVERSION_URL Add --username=USER if needed Update with: git svn rebase Subversion requires a linear history, thus rebase Use Git to develop locally as normal Commit all diffs to Subversion: git svn dcommit
  • 142. YOU CAN NEVER HAVE TOO FEW GEEKS
  • 143. YOU CAN NEVER HAVE TOO FEW GEEKS
  • 144. YOU CAN NEVER HAVE TOO FEW GEEKS I NEED THIS MANY JUST TO PLAY A GAME ONCE A YEAR
  • 145.
  • 147. To Set That Up…
  • 148. To Set That Up… I created a git_server directory on my Desktop
  • 149. To Set That Up… I created a git_server directory on my Desktop I moved my faster_csv repository into it
  • 150. To Set That Up… I created a git_server directory on my Desktop I moved my faster_csv repository into it I ran: git daemon --base-path=/Users/james/ Desktop/git_server --export-all
  • 151. To Set That Up… I created a git_server directory on my Desktop I moved my faster_csv repository into it I ran: git daemon --base-path=/Users/james/ Desktop/git_server --export-all This is read-only (but write support is possible) access on port 9418
  • 152. To Set That Up… I created a git_server directory on my Desktop I moved my faster_csv repository into it I ran: git daemon --base-path=/Users/james/ Desktop/git_server --export-all This is read-only (but write support is possible) access on port 9418 This rocks for when GitHub is down
  • 153.
  • 156. An Instant Web Interface I moved into the Git working directory
  • 157. An Instant Web Interface I moved into the Git working directory I ran: git instaweb --httpd=webrick
  • 158. An Instant Web Interface I moved into the Git working directory I ran: git instaweb --httpd=webrick Later, I will stop it with: git instaweb --stop
  • 159. An Instant Web Interface I moved into the Git working directory I ran: git instaweb --httpd=webrick Later, I will stop it with: git instaweb --stop This is a handy poor man’s repository browser that’s pretty much always available
  • 166. EVERYBODY HAS THEIR SYSTEM DANA HAS ONE JUST FOR FOOD
  • 168. Git Supports Many Work Styles Git’s features make it very flexible
  • 169. Git Supports Many Work Styles Git’s features make it very flexible Non-linear history is fully supported
  • 170. Git Supports Many Work Styles Git’s features make it very flexible Non-linear history is fully supported Powerful history rewriting is provided
  • 171. Git Supports Many Work Styles Git’s features make it very flexible Non-linear history is fully supported Powerful history rewriting is provided All repositories are masters
  • 172. Git Supports Many Work Styles Git’s features make it very flexible Non-linear history is fully supported Powerful history rewriting is provided All repositories are masters Any repository can be distributed
  • 173. Git Supports Many Work Styles Git’s features make it very flexible Non-linear history is fully supported Powerful history rewriting is provided All repositories are masters Any repository can be distributed Many work strategies are built off of these features
  • 175. SAY WE HAVE A BRANCH WITH TWO COMMITS THIS IS A PRETTY TYPICAL GIT SCENARIO, A TOPIC BRANCH OFF OF MASTER
  • 176. FAST FORWARD (A FLAT MERGE) BY DEFAULT, GIT WOULD JUST ADD THESE COMMITS ONTO MASTER
  • 177. YOU CAN FORCE GIT TO KEEP THE BRANCH HTTP://NVIE.COM/GIT-MODEL
  • 178. YOU CAN FORCE GIT TO KEEP THE BRANCH HTTP://NVIE.COM/GIT-MODEL
  • 179. NOTICE HOW GIT ADDED A MERGE COMMIT YOU CAN REVERT THAT ONE COMMIT TO UNDO THE ENTIRE BRANCH
  • 180. NOTICE HOW GIT ADDED A MERGE COMMIT YOU CAN REVERT THAT ONE COMMIT TO UNDO THE ENTIRE BRANCH
  • 181. ALTERNATELY, YOU COULD SQUASH THE COMMITS HTTP://GEEWAX.ORG/2009/11/21/AGILE-GIT-WORKFLOW.HTML
  • 182. ALTERNATELY, YOU COULD SQUASH THE COMMITS HTTP://GEEWAX.ORG/2009/11/21/AGILE-GIT-WORKFLOW.HTML
  • 183. REBASE ASKS ME HOW TO HANDLE EACH COMMIT GIT COMMANDS LIKE ADD AND REBASE SUPPORT A POWERFUL INTERACTIVE MODE
  • 184. REBASE ASKS ME HOW TO HANDLE EACH COMMIT GIT COMMANDS LIKE ADD AND REBASE SUPPORT A POWERFUL INTERACTIVE MODE
  • 185. YOU EVEN GET TO REVISE THE COMMITS COMBINE OR REPLACE THEM TO TASTE
  • 186. YOU EVEN GET TO REVISE THE COMMITS COMBINE OR REPLACE THEM TO TASTE
  • 187. FINALLY, MERGE THE COLLAPSED COMMIT I CAN USE THE POWER OF INTERACTIVE MODE TO COLLAPSE THINGS INTO ONE COMMIT
  • 188. FINALLY, MERGE THE COLLAPSED COMMIT I CAN USE THE POWER OF INTERACTIVE MODE TO COLLAPSE THINGS INTO ONE COMMIT
  • 189. A TOPIC BRANCH WAS REDUCED TO ONE COMMIT THIS IS ANOTHER TECHNIQUE THAT ALLOWS US TO UNDO IT WITH ONE REVERT
  • 190. A TOPIC BRANCH WAS REDUCED TO ONE COMMIT THIS IS ANOTHER TECHNIQUE THAT ALLOWS US TO UNDO IT WITH ONE REVERT
  • 192. YOUR SUBVERSION STRATEGY STILL WORKS FINE THIS IS HOW GITHUB IS COMMONLY USED
  • 193. LINUS USES HIS “CIRCLE OF TRUST” HTTP://WWW.YOUTUBE.COM/WATCH?V=4XPNKHJAOK8
  • 194. LINUS USES HIS “CIRCLE OF TRUST” HTTP://WWW.YOUTUBE.COM/WATCH?V=4XPNKHJAOK8
  • 195. LINUS USES HIS “CIRCLE OF TRUST” HTTP://WWW.YOUTUBE.COM/WATCH?V=4XPNKHJAOK8
  • 197.
  • 198. GitHub is one of Git’s Killer Features
  • 199.
  • 200.
  • 201. THIS IS CALLED “FORKING”
  • 202. THIS IS CALLED “FORKING” DANA IS SPINNING OFF OF A COPY OF GENES WE WILL EDIT SEPARATELY
  • 204. CREATING A GITHUB REPOSITORY IS TRIVIAL PUBLIC, OPEN SOURCE REPOSITORIES ARE FREE!
  • 205. CREATING A GITHUB REPOSITORY IS TRIVIAL PUBLIC, OPEN SOURCE REPOSITORIES ARE FREE!
  • 206. A REPOSITORY ON GITHUB: THE RAILS SOURCE HERE YOU CAN BROWSE OR FORK THE CODE
  • 207. A REPOSITORY ON GITHUB: THE RAILS SOURCE HERE YOU CAN BROWSE OR FORK THE CODE
  • 208. A REPOSITORY ON GITHUB: THE RAILS SOURCE HERE YOU CAN BROWSE OR FORK THE CODE
  • 209. A REPOSITORY ON GITHUB: THE RAILS SOURCE HERE YOU CAN BROWSE OR FORK THE CODE
  • 210. A REPOSITORY ON GITHUB: THE RAILS SOURCE HERE YOU CAN BROWSE OR FORK THE CODE
  • 211. A FORKED REPOSITORY: RIOT THIS FORK IS LINKED BACK TO THE ORIGINAL AND THEY CAN PULL FROM IT
  • 212. A FORKED REPOSITORY: RIOT THIS FORK IS LINKED BACK TO THE ORIGINAL AND THEY CAN PULL FROM IT
  • 213. A FORKED REPOSITORY: RIOT THIS FORK IS LINKED BACK TO THE ORIGINAL AND THEY CAN PULL FROM IT
  • 214. A FORKED REPOSITORY: RIOT THIS FORK IS LINKED BACK TO THE ORIGINAL AND THEY CAN PULL FROM IT
  • 215. A FORKED REPOSITORY: RIOT THIS FORK IS LINKED BACK TO THE ORIGINAL AND THEY CAN PULL FROM IT
  • 216. THE NETWORK GRAPH THIS IS WHERE YOU CAN SEE HOW ALL OF THE FORKS RELATE
  • 217. THE NETWORK GRAPH THIS IS WHERE YOU CAN SEE HOW ALL OF THE FORKS RELATE
  • 218. THE NETWORK GRAPH THIS IS WHERE YOU CAN SEE HOW ALL OF THE FORKS RELATE
  • 219. THE NETWORK GRAPH THIS IS WHERE YOU CAN SEE HOW ALL OF THE FORKS RELATE
  • 220. THE FORK QUEUE CAN MERGE EXTERNAL CHANGES I PREFER TO HANDLE THIS REMOTES SO A CAN WORK WITH NORMAL BRANCHES
  • 221. THE FORK QUEUE CAN MERGE EXTERNAL CHANGES I PREFER TO HANDLE THIS REMOTES SO A CAN WORK WITH NORMAL BRANCHES
  • 222. THE FORK QUEUE CAN MERGE EXTERNAL CHANGES I PREFER TO HANDLE THIS REMOTES SO A CAN WORK WITH NORMAL BRANCHES
  • 223. MY FORK AND THE OFFICIAL GIT’S REMOTES CAN MANAGE ANY NUMBER OF RELATED REPOSITORIES
  • 224. MY FORK AND THE OFFICIAL GIT’S REMOTES CAN MANAGE ANY NUMBER OF RELATED REPOSITORIES
  • 225. MY FORK AND THE OFFICIAL GIT’S REMOTES CAN MANAGE ANY NUMBER OF RELATED REPOSITORIES
  • 226. MY FORK AND THE OFFICIAL GIT’S REMOTES CAN MANAGE ANY NUMBER OF RELATED REPOSITORIES
  • 227. FETCHING A REMOTE GIT FETCH ALLOWS YOU TO ADD ALL DETAILS OF A REMOTE TO YOUR LOCAL COPY
  • 228. FETCHING A REMOTE GIT FETCH ALLOWS YOU TO ADD ALL DETAILS OF A REMOTE TO YOUR LOCAL COPY
  • 229. PLAY WITH CODE FROM A REMOTE LOCAL BRANCHES CAN TRACK REMOTE BRANCHES
  • 230. PLAY WITH CODE FROM A REMOTE LOCAL BRANCHES CAN TRACK REMOTE BRANCHES
  • 231. PLAY WITH CODE FROM A REMOTE LOCAL BRANCHES CAN TRACK REMOTE BRANCHES
  • 232. FULLY SHARE WITH COLLABORATORS A COLLABORATOR CAN USE THE CODE LIKE YOU WITHOUT PULL REQUESTS
  • 233. FULLY SHARE WITH COLLABORATORS A COLLABORATOR CAN USE THE CODE LIKE YOU WITHOUT PULL REQUESTS
  • 234. FULLY SHARE WITH COLLABORATORS A COLLABORATOR CAN USE THE CODE LIKE YOU WITHOUT PULL REQUESTS
  • 235. Gists
  • 236.
  • 237.
  • 239. OUR NEIGHBOR’S YARD SOME THINGS ARE TOO GOOD NOT TO SHARE
  • 240. A GIT-CENTRIC CODE PASTING SERVICE PASTE ONE OR MORE FILES TAGGED WITH A LANGUAGE
  • 241. A GIT-CENTRIC CODE PASTING SERVICE PASTE ONE OR MORE FILES TAGGED WITH A LANGUAGE
  • 242. A GIT-CENTRIC CODE PASTING SERVICE PASTE ONE OR MORE FILES TAGGED WITH A LANGUAGE
  • 243. A GIT-CENTRIC CODE PASTING SERVICE PASTE ONE OR MORE FILES TAGGED WITH A LANGUAGE
  • 244. IT’S A PASTE AND A GIT REPOSITORY YOU CAN FORK THIS CODE OR CLONE IT TO WORK WITH LOCALLY
  • 245. IT’S A PASTE AND A GIT REPOSITORY YOU CAN FORK THIS CODE OR CLONE IT TO WORK WITH LOCALLY
  • 246. Hooks
  • 247. IT’S ALWAYS GOOD TO HAVE TRAINED HELP
  • 248. IT’S ALWAYS GOOD TO HAVE TRAINED HELP
  • 249. IT’S ALWAYS GOOD TO HAVE TRAINED HELP YOU CAN TEACH GIT AND GITHUB NEW TRICKS
  • 250. GIT HOOKS THE POST-COMMIT HOOK CAN BE USED TO AUTO TAG RELEASES
  • 251. GIT HOOKS THE POST-COMMIT HOOK CAN BE USED TO AUTO TAG RELEASES
  • 252. GIT HOOKS THE POST-COMMIT HOOK CAN BE USED TO AUTO TAG RELEASES
  • 253. GITHUB SUPPORTS HOOKS POST TO A URL, SEND AN EMAIL, OR MORE WHEN GITHUB IS PUSHED TO
  • 254. GITHUB SUPPORTS HOOKS POST TO A URL, SEND AN EMAIL, OR MORE WHEN GITHUB IS PUSHED TO
  • 255. GITHUB SUPPORTS HOOKS POST TO A URL, SEND AN EMAIL, OR MORE WHEN GITHUB IS PUSHED TO
  • 256. GITHUB SUPPORTS HOOKS POST TO A URL, SEND AN EMAIL, OR MORE WHEN GITHUB IS PUSHED TO
  • 261. FIRST IMPRESSIONS MATTER YOU HAVE TO ADVERTISE WHAT’S INSIDE
  • 262. GITHUB IS SMART ABOUT README FORMATS IT WILL SHOW README FILES IN EACH FOLDER AND HTMLIFY SOME CONTENT TYPES
  • 263. GITHUB IS SMART ABOUT README FORMATS IT WILL SHOW README FILES IN EACH FOLDER AND HTMLIFY SOME CONTENT TYPES
  • 264. GITHUB IS SMART ABOUT README FORMATS IT WILL SHOW README FILES IN EACH FOLDER AND HTMLIFY SOME CONTENT TYPES
  • 267. Supported Formats RDoc (.rdoc) Reuse your Ruby project documentation
  • 268. Supported Formats RDoc (.rdoc) Reuse your Ruby project documentation Markdown (.markdown, .md, .mdown, …)
  • 269. Supported Formats RDoc (.rdoc) Reuse your Ruby project documentation Markdown (.markdown, .md, .mdown, …) A human-readable format for other projects
  • 270. Supported Formats RDoc (.rdoc) Reuse your Ruby project documentation Markdown (.markdown, .md, .mdown, …) A human-readable format for other projects Also supported: Textile (.textile), PNG (.png), reStructuredText (.rst), and POD (.pod)
  • 272. OUR NEW OK.RB WEBSITE: HTTP://OK-RUBY.ORG/
  • 273. OUR NEW OK.RB WEBSITE: HTTP://OK-RUBY.ORG/
  • 274. OUR NEW OK.RB WEBSITE: HTTP://OK-RUBY.ORG/ YOU CAN HELP MAKE THIS BETTER
  • 275. IT’S A PROJECT ON GITHUB THE GITHUB PAGES FEATURE TURNS THIS INTO A REAL SITE
  • 276. IT’S A PROJECT ON GITHUB THE GITHUB PAGES FEATURE TURNS THIS INTO A REAL SITE
  • 278. GitHub Pages Name a repository after you: USER.github.com
  • 279. GitHub Pages Name a repository after you: USER.github.com Or add a gh-pages branch to any repository
  • 280. GitHub Pages Name a repository after you: USER.github.com Or add a gh-pages branch to any repository GitHub will build the site after each commit
  • 281. GitHub Pages Name a repository after you: USER.github.com Or add a gh-pages branch to any repository GitHub will build the site after each commit Sites are Jekyll (a static site generator) processed
  • 282. GitHub Pages Name a repository after you: USER.github.com Or add a gh-pages branch to any repository GitHub will build the site after each commit Sites are Jekyll (a static site generator) processed Used to build listings, syntax highlight, etc.
  • 283. GitHub Pages Name a repository after you: USER.github.com Or add a gh-pages branch to any repository GitHub will build the site after each commit Sites are Jekyll (a static site generator) processed Used to build listings, syntax highlight, etc. You can point a real domain at them
  • 285.
  • 286.
  • 287. IF YOU FELL ASLEEP IN THIS TALK…
  • 288. IF YOU FELL ASLEEP IN THIS TALK… YOU MAY NEED TO RTFM
  • 289. Where to Find the Docs
  • 290. Where to Find the Docs Git has awesome man(ual) pages
  • 291. Where to Find the Docs Git has awesome man(ual) pages Replace spaces with dashes: man git-stash
  • 292. Where to Find the Docs Git has awesome man(ual) pages Replace spaces with dashes: man git-stash Scott Chacon’s (GitHub’s Git Guru) Pro Git book
  • 293. Where to Find the Docs Git has awesome man(ual) pages Replace spaces with dashes: man git-stash Scott Chacon’s (GitHub’s Git Guru) Pro Git book Free online: http://progit.org/
  • 294. Where to Find the Docs Git has awesome man(ual) pages Replace spaces with dashes: man git-stash Scott Chacon’s (GitHub’s Git Guru) Pro Git book Free online: http://progit.org/ GitHub has good guides: http://help.github.com/
  • 295. Where to Find the Docs Git has awesome man(ual) pages Replace spaces with dashes: man git-stash Scott Chacon’s (GitHub’s Git Guru) Pro Git book Free online: http://progit.org/ GitHub has good guides: http://help.github.com/ They cover GitHub and Git topics
  • 296.
  • 297. You have passed this endurance test!

Editor's Notes