SlideShare a Scribd company logo
Git in one Evening
● Who am I, and what is my context?
● Why use version control at all?
● What are the options?
● Why choose git?
● Git basics
● Github goodies
● Git as part of your workflow
● Questions and discussion
Who am I, anyway?
● Long time developer (perl, php)
● Primarily work in Drupal
● I work with a small team – I'm the primary
back-end dev, we have one themer
● I do sometimes contribute to the Drupal
project.
Why use version control?
● Also called “revision control” or “source
control”
● Use cases (code == text files)
– Solo, CMS site building, no custom code
(useful at times)
– Solo, CMS site building, custom code (theme
files, etc.) (very useful)
– Solo or Team, custom code (essential)
– Team, CMS site building, custom code
(essential)
Version Control Options
● Old skool: CVS/SVN (client/server)
● New skool: Git, Bazaar, Mercurial (distributed)
● Git is by far the most popular, and has
become the industry standard for version
control. Used for the Linux kernel
● Mercurial is used by Python, and others
● Bazaar is used by Ubuntu, and supported by
Canonical
Distributed Version Control
● SVN (and its predecessor, CVS) had only
one repository, and it was central. You
committed code to that repository. Your
working copy is only a copy of the code, with
metadata (in the form of .svn directories).
● With distributed version control, everyone has
a repository – so every version is basically a
fork.
Distributed Version Control, cont.
● Synchronization can happen by peers
exchanging patches
● Commits, reverts, etc. are fast, because they
happen locally.
● You can work productively (like on a plane)
without having to connect to a server
● Branching and forking are a lot easier
● It is easier to contribute to open source
projects
Why Learn Git?
● It is distributed version control
● It is the most popular
● It is used for the drupal project (I notice
wordpress is still using SVN.)
● It is in increasing use in PaaS systems
(Heroku, etc.)
● You'll improve your chances of getting a job
(git knowledge is increasingly asked for.)
How to get git
● Linux
– apt-get install git (Ubuntu/Debian)
– yum install git-core (Fedora/CentOS)
– Download from http://git-scm.com/
● Mac OS X
– Graphical Git
installer:http://code.google.com/p/git-osx-
installer
– MacPorts
● Windows
– http://msysgit.github.io/
Git Tools
● IDEs/Editors that integrate with git
– Eclipse
– Netbeans
– TextMate
● Git GUIs
– Gitg
– Katana
– Others
● https://git.wiki.kernel.org/index.php/InterfacesF
rontendsAndTools
Git GUI (gitg)
Basic Git
● Creating a git repository
● Cloning a git repository
● Making changes
● Viewing status
● Staging changes
● Committing changes
● Pushing and Pulling
● Undoing mistakes
More Git Commands
● Clone a repository: ‘git clone
ssh://user@domain/repo.git’
● Add an origin: ‘git remote add <remote>
user@domain/repo.git’
● Pulling from a remote: ‘git pull <remote>
<branch>
Let’s Do It!
Git Repository Hosting
● You could theoretically do peer-to-peer, but
the standard is to have a “bare” repository
hosted somewhere
● You can easily host it yourself on a VPS
● Commercial hosting options provide goodies
– GitHub
– Bitbucket
– Others
GitHub
● github.com
● Free for open source/public projects
● Modest cost for private repository hosting
● Lots of nice goodies, including issue tracking
Git Workflow
● Depends on use case
● Teams
● Branches
● Remotes as “servers” a la cvs/svn
● Challenges integrating with DB based CMS
config changes
Got Questions?
● I might have answers
Michelle Murrain
● michelle@murrain.net
● @pearlbear on twitter
● pearlbear on d.o.

More Related Content

PPTX
Mono Repo
Zacky Pickholz
 
PPTX
Advantages and disadvantages of a monorepo
IanDavidson56
 
PDF
Monorepo at Pinterest
Suman Karumuri
 
PDF
Local Community for Debian (2013 Taiwan miniDebConf)
Hideki Yamane
 
PDF
Automated deployment
Sardorbek Muminov
 
PPTX
Master the Monorepo
Roman Minchyn
 
PDF
8-9-10=Jessie,Stretch,Buster
Hideki Yamane
 
PDF
Continuous Deployment of Front-end JavaScript with StriderCD, Github and Sauc...
niallo
 
Mono Repo
Zacky Pickholz
 
Advantages and disadvantages of a monorepo
IanDavidson56
 
Monorepo at Pinterest
Suman Karumuri
 
Local Community for Debian (2013 Taiwan miniDebConf)
Hideki Yamane
 
Automated deployment
Sardorbek Muminov
 
Master the Monorepo
Roman Minchyn
 
8-9-10=Jessie,Stretch,Buster
Hideki Yamane
 
Continuous Deployment of Front-end JavaScript with StriderCD, Github and Sauc...
niallo
 

What's hot (20)

ODP
Git: be social
Geronimo Orozco
 
ODP
Intro to XPages for Administrators (DanNotes, November 28, 2012)
Per Henrik Lausten
 
PDF
Introduction To Dart (GDG NY Jan 2014 Meetup)
Nitya Narasimhan
 
PDF
Composer
Naseer Ahmad
 
PDF
Atomic Developer Bundle
Dharmit Shah
 
PDF
Kubernetes
Dharmit Shah
 
PDF
Custom angular libraries
MattVaughn9
 
ODP
DevOps Cebu Presentation
Neil Alwin Hermosilla
 
ODP
Beginning python programming
kanteshraj
 
ODP
Intro to CrunchBang / Linux Fest Northwest 2013
Larry Cafiero
 
PDF
Profile all the things! - Capital Go 2017
John Potocny
 
PDF
What the HACK is HHVM?
Hean Hong Leong
 
ODP
Introduction to Vim 8.0
k-takata
 
ODP
Debian packaging talk, Pysheff sept 2012
takluyver
 
ODP
Vagrant and puppet: Deployment made easy
Geronimo Orozco
 
PDF
Goodpractice
Lorna Mitchell
 
PPTX
From NodeJS to Rust
Bastian Gruber
 
ODP
Introducing Yeoman 1.0 beta
digitalzombie
 
PDF
DIEMS Repository Server - GitLab
Mayur Deshmukh
 
PDF
Stop Sucking at Building Stuff!
Puppet
 
Git: be social
Geronimo Orozco
 
Intro to XPages for Administrators (DanNotes, November 28, 2012)
Per Henrik Lausten
 
Introduction To Dart (GDG NY Jan 2014 Meetup)
Nitya Narasimhan
 
Composer
Naseer Ahmad
 
Atomic Developer Bundle
Dharmit Shah
 
Kubernetes
Dharmit Shah
 
Custom angular libraries
MattVaughn9
 
DevOps Cebu Presentation
Neil Alwin Hermosilla
 
Beginning python programming
kanteshraj
 
Intro to CrunchBang / Linux Fest Northwest 2013
Larry Cafiero
 
Profile all the things! - Capital Go 2017
John Potocny
 
What the HACK is HHVM?
Hean Hong Leong
 
Introduction to Vim 8.0
k-takata
 
Debian packaging talk, Pysheff sept 2012
takluyver
 
Vagrant and puppet: Deployment made easy
Geronimo Orozco
 
Goodpractice
Lorna Mitchell
 
From NodeJS to Rust
Bastian Gruber
 
Introducing Yeoman 1.0 beta
digitalzombie
 
DIEMS Repository Server - GitLab
Mayur Deshmukh
 
Stop Sucking at Building Stuff!
Puppet
 
Ad

Similar to Git In One Evening (20)

PDF
Intro to Git for Drupal 7
Chris Caple
 
PDF
Harvard ABCD-WWW Git presentation
Jeff Byrnes
 
PPTX
Introduction to git hub
Naveen Pandey
 
PDF
Git Pocket Guide A Working Introduction 1st Edition Richard E. Silverman
fingonbinka66
 
PDF
Version Control with Git
Luigi De Russis
 
PDF
Mini git tutorial
Cristian Lucchesi
 
PDF
Why Git Sucks and you'll use it anyways
Carlos Taborda
 
PDF
Git: a tool for wizards
responseteam
 
PDF
Introduction to Git and Github - Google Developer Student Clubs CET, Trivandrum
AbhijitNarayan2
 
PDF
Version Control System - Git
Carlo Bernaschina
 
KEY
Let's Git this Party Started: An Introduction to Git and GitHub
Kim Moir
 
PPT
Introduction to git
Nguyen Van Hung
 
PDF
Starting with Git & GitHub
Nicolás Tourné
 
PPTX
Introduction to GitHub, Open Source and Tech Article
PRIYATHAMDARISI
 
PDF
Rc094 010d-git 2 - desconocido
Luis Bertel
 
ODP
Git slides
55020
 
PDF
Github - Git Training Slides: Foundations
Lee Hanxue
 
PPT
Git and GitHUB Explanation and simple coding for CLI
kumaresan7751
 
PPT
git2nvlkndvslnvdslnlknvdlnlvdsnlknsdvlkn.ppt
loleto7559
 
Intro to Git for Drupal 7
Chris Caple
 
Harvard ABCD-WWW Git presentation
Jeff Byrnes
 
Introduction to git hub
Naveen Pandey
 
Git Pocket Guide A Working Introduction 1st Edition Richard E. Silverman
fingonbinka66
 
Version Control with Git
Luigi De Russis
 
Mini git tutorial
Cristian Lucchesi
 
Why Git Sucks and you'll use it anyways
Carlos Taborda
 
Git: a tool for wizards
responseteam
 
Introduction to Git and Github - Google Developer Student Clubs CET, Trivandrum
AbhijitNarayan2
 
Version Control System - Git
Carlo Bernaschina
 
Let's Git this Party Started: An Introduction to Git and GitHub
Kim Moir
 
Introduction to git
Nguyen Van Hung
 
Starting with Git & GitHub
Nicolás Tourné
 
Introduction to GitHub, Open Source and Tech Article
PRIYATHAMDARISI
 
Rc094 010d-git 2 - desconocido
Luis Bertel
 
Git slides
55020
 
Github - Git Training Slides: Foundations
Lee Hanxue
 
Git and GitHUB Explanation and simple coding for CLI
kumaresan7751
 
git2nvlkndvslnvdslnlknvdlnlvdsnlknsdvlkn.ppt
loleto7559
 
Ad

More from Maxwell Pearl (10)

PDF
Cloudcomputing.072110
Maxwell Pearl
 
ODP
Open Source Software You Can Use
Maxwell Pearl
 
ODP
Drupal Webinar
Maxwell Pearl
 
ODP
Open Source Databases Webinar
Maxwell Pearl
 
ODP
Joomla Webinar
Maxwell Pearl
 
PPT
Open Source Blogging Tools
Maxwell Pearl
 
ODP
CRM Webinar
Maxwell Pearl
 
ODP
OpenOffice.Org Webinar 0208
Maxwell Pearl
 
ODP
Foss Support Webinar0108
Maxwell Pearl
 
ODP
Open Standards0607
Maxwell Pearl
 
Cloudcomputing.072110
Maxwell Pearl
 
Open Source Software You Can Use
Maxwell Pearl
 
Drupal Webinar
Maxwell Pearl
 
Open Source Databases Webinar
Maxwell Pearl
 
Joomla Webinar
Maxwell Pearl
 
Open Source Blogging Tools
Maxwell Pearl
 
CRM Webinar
Maxwell Pearl
 
OpenOffice.Org Webinar 0208
Maxwell Pearl
 
Foss Support Webinar0108
Maxwell Pearl
 
Open Standards0607
Maxwell Pearl
 

Recently uploaded (20)

PPTX
What-is-the-World-Wide-Web -- Introduction
tonifi9488
 
PDF
How-Cloud-Computing-Impacts-Businesses-in-2025-and-Beyond.pdf
Artjoker Software Development Company
 
PDF
BLW VOCATIONAL TRAINING SUMMER INTERNSHIP REPORT
codernjn73
 
PDF
A Day in the Life of Location Data - Turning Where into How.pdf
Precisely
 
PDF
Doc9.....................................
SofiaCollazos
 
PDF
Presentation about Hardware and Software in Computer
snehamodhawadiya
 
PDF
The Future of Artificial Intelligence (AI)
Mukul
 
PPTX
New ThousandEyes Product Innovations: Cisco Live June 2025
ThousandEyes
 
PDF
The Evolution of KM Roles (Presented at Knowledge Summit Dublin 2025)
Enterprise Knowledge
 
PPTX
Dev Dives: Automate, test, and deploy in one place—with Unified Developer Exp...
AndreeaTom
 
PDF
Get More from Fiori Automation - What’s New, What Works, and What’s Next.pdf
Precisely
 
PPTX
cloud computing vai.pptx for the project
vaibhavdobariyal79
 
PPTX
AI and Robotics for Human Well-being.pptx
JAYMIN SUTHAR
 
PDF
AI Unleashed - Shaping the Future -Starting Today - AIOUG Yatra 2025 - For Co...
Sandesh Rao
 
PDF
Orbitly Pitch Deck|A Mission-Driven Platform for Side Project Collaboration (...
zz41354899
 
PPTX
Applied-Statistics-Mastering-Data-Driven-Decisions.pptx
parmaryashparmaryash
 
PDF
Economic Impact of Data Centres to the Malaysian Economy
flintglobalapac
 
PDF
How Open Source Changed My Career by abdelrahman ismail
a0m0rajab1
 
PDF
Google I/O Extended 2025 Baku - all ppts
HusseinMalikMammadli
 
PPTX
AI in Daily Life: How Artificial Intelligence Helps Us Every Day
vanshrpatil7
 
What-is-the-World-Wide-Web -- Introduction
tonifi9488
 
How-Cloud-Computing-Impacts-Businesses-in-2025-and-Beyond.pdf
Artjoker Software Development Company
 
BLW VOCATIONAL TRAINING SUMMER INTERNSHIP REPORT
codernjn73
 
A Day in the Life of Location Data - Turning Where into How.pdf
Precisely
 
Doc9.....................................
SofiaCollazos
 
Presentation about Hardware and Software in Computer
snehamodhawadiya
 
The Future of Artificial Intelligence (AI)
Mukul
 
New ThousandEyes Product Innovations: Cisco Live June 2025
ThousandEyes
 
The Evolution of KM Roles (Presented at Knowledge Summit Dublin 2025)
Enterprise Knowledge
 
Dev Dives: Automate, test, and deploy in one place—with Unified Developer Exp...
AndreeaTom
 
Get More from Fiori Automation - What’s New, What Works, and What’s Next.pdf
Precisely
 
cloud computing vai.pptx for the project
vaibhavdobariyal79
 
AI and Robotics for Human Well-being.pptx
JAYMIN SUTHAR
 
AI Unleashed - Shaping the Future -Starting Today - AIOUG Yatra 2025 - For Co...
Sandesh Rao
 
Orbitly Pitch Deck|A Mission-Driven Platform for Side Project Collaboration (...
zz41354899
 
Applied-Statistics-Mastering-Data-Driven-Decisions.pptx
parmaryashparmaryash
 
Economic Impact of Data Centres to the Malaysian Economy
flintglobalapac
 
How Open Source Changed My Career by abdelrahman ismail
a0m0rajab1
 
Google I/O Extended 2025 Baku - all ppts
HusseinMalikMammadli
 
AI in Daily Life: How Artificial Intelligence Helps Us Every Day
vanshrpatil7
 

Git In One Evening

  • 1. Git in one Evening ● Who am I, and what is my context? ● Why use version control at all? ● What are the options? ● Why choose git? ● Git basics ● Github goodies ● Git as part of your workflow ● Questions and discussion
  • 2. Who am I, anyway? ● Long time developer (perl, php) ● Primarily work in Drupal ● I work with a small team – I'm the primary back-end dev, we have one themer ● I do sometimes contribute to the Drupal project.
  • 3. Why use version control? ● Also called “revision control” or “source control” ● Use cases (code == text files) – Solo, CMS site building, no custom code (useful at times) – Solo, CMS site building, custom code (theme files, etc.) (very useful) – Solo or Team, custom code (essential) – Team, CMS site building, custom code (essential)
  • 4. Version Control Options ● Old skool: CVS/SVN (client/server) ● New skool: Git, Bazaar, Mercurial (distributed) ● Git is by far the most popular, and has become the industry standard for version control. Used for the Linux kernel ● Mercurial is used by Python, and others ● Bazaar is used by Ubuntu, and supported by Canonical
  • 5. Distributed Version Control ● SVN (and its predecessor, CVS) had only one repository, and it was central. You committed code to that repository. Your working copy is only a copy of the code, with metadata (in the form of .svn directories). ● With distributed version control, everyone has a repository – so every version is basically a fork.
  • 6. Distributed Version Control, cont. ● Synchronization can happen by peers exchanging patches ● Commits, reverts, etc. are fast, because they happen locally. ● You can work productively (like on a plane) without having to connect to a server ● Branching and forking are a lot easier ● It is easier to contribute to open source projects
  • 7. Why Learn Git? ● It is distributed version control ● It is the most popular ● It is used for the drupal project (I notice wordpress is still using SVN.) ● It is in increasing use in PaaS systems (Heroku, etc.) ● You'll improve your chances of getting a job (git knowledge is increasingly asked for.)
  • 8. How to get git ● Linux – apt-get install git (Ubuntu/Debian) – yum install git-core (Fedora/CentOS) – Download from http://git-scm.com/ ● Mac OS X – Graphical Git installer:http://code.google.com/p/git-osx- installer – MacPorts ● Windows – http://msysgit.github.io/
  • 9. Git Tools ● IDEs/Editors that integrate with git – Eclipse – Netbeans – TextMate ● Git GUIs – Gitg – Katana – Others ● https://git.wiki.kernel.org/index.php/InterfacesF rontendsAndTools
  • 11. Basic Git ● Creating a git repository ● Cloning a git repository ● Making changes ● Viewing status ● Staging changes ● Committing changes ● Pushing and Pulling ● Undoing mistakes
  • 12. More Git Commands ● Clone a repository: ‘git clone ssh://user@domain/repo.git’ ● Add an origin: ‘git remote add <remote> user@domain/repo.git’ ● Pulling from a remote: ‘git pull <remote> <branch>
  • 14. Git Repository Hosting ● You could theoretically do peer-to-peer, but the standard is to have a “bare” repository hosted somewhere ● You can easily host it yourself on a VPS ● Commercial hosting options provide goodies – GitHub – Bitbucket – Others
  • 15. GitHub ● github.com ● Free for open source/public projects ● Modest cost for private repository hosting ● Lots of nice goodies, including issue tracking
  • 16. Git Workflow ● Depends on use case ● Teams ● Branches ● Remotes as “servers” a la cvs/svn ● Challenges integrating with DB based CMS config changes
  • 17. Got Questions? ● I might have answers
  • 18. Michelle Murrain ● [email protected] @pearlbear on twitter ● pearlbear on d.o.