SlideShare a Scribd company logo
Enterprise Git
Pedro Melo
<{xmpp,mailto}:melo@simplicidade.org>
About Git...
About Git...
an unpleasant or contemptible person
Why Git?
Why Git?
• Fast, secure, safe, solid
Why Git?
• Fast, secure, safe, solid
• Great collaboration tools: built-in and from
third parties
Why Git?
• Fast, secure, safe, solid
• Great collaboration tools: built-in and from
third parties
• Distributed (think offline mode, freedom to
tinker)
Why Git?
• Fast, secure, safe, solid
• Great collaboration tools: built-in and from
third parties
• Distributed (think offline mode, freedom to
tinker)
• Cross-platform: UNIX, Mac OS X,Windows
Why Git?
• Fast, secure, safe, solid
• Great collaboration tools: built-in and from
third parties
• Distributed (think offline mode, freedom to
tinker)
• Cross-platform: UNIX, Mac OS X,Windows
• Proven track record: Linux Kernel, KDE,
X.org, KDE, Gnome,Android, Debian,
Fedora, openSUSE, Mono, Perl, Ruby, Samba,
PostgreSQL,Wine, and many others
Adoption challenges
Adoption challenges
The devil you know....
Adoption challenges
Adoption challenges
Centralized vs Distributed
Adoption challenges
Adoption challenges
Liberal branching
Tools
Git “Server”
Git “Server”
• “Server” is what you want it to be: an SSH
account, a simple HTTP server, or a CGI-
capable HTTP server
Git “Server”
• “Server” is what you want it to be: an SSH
account, a simple HTTP server, or a CGI-
capable HTTP server
• No centralized server built-in concept
Git “Server”
• “Server” is what you want it to be: an SSH
account, a simple HTTP server, or a CGI-
capable HTTP server
• No centralized server built-in concept
• One or more repositories in well-known
locations become the central repository
Git “Server”
• “Server” is what you want it to be: an SSH
account, a simple HTTP server, or a CGI-
capable HTTP server
• No centralized server built-in concept
• One or more repositories in well-known
locations become the central repository
• Social convention wins
Centralized Git Servers
Centralized Git Servers
Gitosis Gitolite
Managed by git Managed by git + shell
Maintained? Active development
repo x user
repo x user x branch x
action
Centralized Git Servers
Gitosis Gitolite
Managed by git Managed by git + shell
Maintained? Active development
repo x user
repo x user x branch x
action
Centralized Git Servers
Gitosis Gitolite
Managed by git Managed by git + shell
Maintained? Active development
repo x user
repo x user x branch x
action
Centralized Git Servers
Gitosis Gitolite
Managed by git Managed by git + shell
Maintained? Active development
repo x user
repo x user x branch x
action
Git + Project Mgmt
Git + Project Mgmt
• OSS
• Redmine
• Trac
• Hosted
• Github (also has in-house solution)
• CodeBaseHQ
Git + Project Mgmt
• OSS
• Redmine
• Trac
• Hosted
• Github (also has in-house solution)
• CodeBaseHQ
Git + Project Mgmt
• OSS
• Redmine
• Trac
• Hosted
• Github (also has in-house solution)
• CodeBaseHQ
One final tool...
One final tool...
• Hudson
One final tool...
• Hudson
• Continuous integration solution
One final tool...
• Hudson
• Continuous integration solution
• Integrates very well with Git
One final tool...
• Hudson
• Continuous integration solution
• Integrates very well with Git
• Its *very* easy to install
One final tool...
• Hudson
• Continuous integration solution
• Integrates very well with Git
• Its *very* easy to install
• ... and it has Chuck Norris quotes!
Team organization
Linux Kernel
General
Lieutenant
A
Lieutenant
B
Lieutenant
C
Official
Army
Common organization
Developers
Smoker Collaboration Production
Lets talk about
merging...
Merge
master
Merge
master
feature
git checkout -b feature
Merge
feature
master
Merge
feature
master
git checkout master; git merge feature
Merge
feature
master
git checkout master; git reset --hard master^
git checkout master; git reset --hard HEAD^
Merge
master
feature
git checkout feature; git merge master
Merge
feature
master
git checkout master; git merge feature
Merge
master
feature
Rebase
feature
master
Rebase
feature
master
A B C
X Y Z
Rebase
master
A B C
X Y Z
X' Y' Z'
feature
git checkout feature; git rebase master
Rebase
master
A B C
X Y Z
X' Y' Z'
feature
dAX
dXY dYZ
dAX'
dXY' dYZ'
Rebase
master
A B C
X Y Z
X' Y' Z'
feature
Rebase
A B C
X Y Z
X' Y' Z'
feature
master
git checkout master; git merge feature
Rebase
master
A B C
X Y Z
X' Y' Z'
feature
Rebase
A B C
X Y Z
X' Y' Z'
feature
D
master
git checkout master; git merge --no-ff feature
Branch naming
git branches
• Byte strings, so mixing codepages bad idea
• Use directories to organize branches
• feature/*, test/*, <dev_handle>/*
• Think globally to minimize clashes
Project phases
Project phases
• Production
Project phases
• Production
• Releases
Project phases
• Production
• Releases
• Staging
Project phases
• Production
• Releases
• Staging
• Features
Project phases
• Production
• Releases
• Staging
• Features
• Celsadas HotFixes
Common branch
names
Common branch
names
• Everybody has a production branch: master
Common branch
names
• Everybody has a production branch: master
• Release branches: release/*
Common branch
names
• Everybody has a production branch: master
• Release branches: release/*
• New features get a branch each: feature/*
Common branch
names
• Everybody has a production branch: master
• Release branches: release/*
• New features get a branch each: feature/*
• If you have multiple developers on the
same feature: feature/NAME/DEV
Common branch
names
• Everybody has a production branch: master
• Release branches: release/*
• New features get a branch each: feature/*
• If you have multiple developers on the
same feature: feature/NAME/DEV
• If you need a “next production”: develop
Common branch
names
• Everybody has a production branch: master
• Release branches: release/*
• New features get a branch each: feature/*
• If you have multiple developers on the
same feature: feature/NAME/DEV
• If you need a “next production”: develop
• When things go wrong: hotfix/*
Conclusions
Conclusions
• Git is ready for big teams
Conclusions
• Git is ready for big teams
• Git is also ready for small teams
Conclusions
• Git is ready for big teams
• Git is also ready for small teams
• There is no right way...
Conclusions
• Git is ready for big teams
• Git is also ready for small teams
• There is no right way...
• ... but start with current best practices
Conclusions
• Git is ready for big teams
• Git is also ready for small teams
• There is no right way...
• ... but start with current best practices
• Whatever you do, the important thing is to
use a source control system
Obrigado!
Pedro Melo
melo@simplicidade.org
@pedromelo
Questions about Git, Perl,
XMPP, just find me and ask away
I’ll be here the three days

More Related Content

PPT
Git Introduction
PDF
Brief tutorial on Git
PDF
沒有 GUI 的 Git
PDF
Introduction to Git, DrupalCamp LA 2015
PPTX
Introduction to git administration
PPTX
Git Presentation
PPTX
Git Lab Introduction
PPTX
Github basics
Git Introduction
Brief tutorial on Git
沒有 GUI 的 Git
Introduction to Git, DrupalCamp LA 2015
Introduction to git administration
Git Presentation
Git Lab Introduction
Github basics

What's hot (20)

PDF
Git: A Getting Started Presentation
PDF
Introduction to GitHub
PDF
How we scaled git lab for a 30k employee company
PDF
Github Case Study By Amil Ali
PDF
Git Educated About Git - 20 Essential Commands
PDF
Starting with Git & GitHub
PDF
Git 101 tutorial presentation
PPTX
Introduction to github slideshare
PPTX
Introduction to git and Github
PDF
How Git and Gerrit make you more productive
PPTX
Git and GitHub | Concept about Git and GitHub Process | Git Process overview
PPTX
Git Tutorial For Beginners | What is Git and GitHub? | DevOps Tools | DevOps ...
PDF
Git and Github
PPTX
Git and Github Session
PDF
Git training
PDF
Git Tutorial I
PPTX
Gerrit is Getting Native with RPM, Deb and Docker
PDF
Git Tutorial
PDF
GitLab as an Alternative Development Platform for Github.com
PDF
Git and github fundamental
Git: A Getting Started Presentation
Introduction to GitHub
How we scaled git lab for a 30k employee company
Github Case Study By Amil Ali
Git Educated About Git - 20 Essential Commands
Starting with Git & GitHub
Git 101 tutorial presentation
Introduction to github slideshare
Introduction to git and Github
How Git and Gerrit make you more productive
Git and GitHub | Concept about Git and GitHub Process | Git Process overview
Git Tutorial For Beginners | What is Git and GitHub? | DevOps Tools | DevOps ...
Git and Github
Git and Github Session
Git training
Git Tutorial I
Gerrit is Getting Native with RPM, Deb and Docker
Git Tutorial
GitLab as an Alternative Development Platform for Github.com
Git and github fundamental
Ad

Viewers also liked (6)

PDF
EDA with SAPO Broker
PDF
Perl Instruments
KEY
Plack
PDF
WTF is XMPP?
PPT
Large-scale digitisation options at the Natural History Museum, London.
PDF
Git Internals
EDA with SAPO Broker
Perl Instruments
Plack
WTF is XMPP?
Large-scale digitisation options at the Natural History Museum, London.
Git Internals
Ad

Similar to Enterprise git (20)

ZIP
Beginner's Guide to Version Control with Git
PPTX
Git-guidance for beginner- IT support.pptx.pptx
PPTX
Git-guidance for beginner- IT support.pptx
PPT
PPTX
Git One Day Training Notes
PPTX
Learn Git - For Beginners and Intermediate levels
ODP
GIT from n00b
PPT
Github By Nyros Developer
PPTX
Practical Git - NYC Code Camp
PPTX
Mini-training: Let’s Git It!
PDF
The Basics of Open Source Collaboration With Git and GitHub
PDF
Git for folk who like GUIs
PDF
Git workshop
PDF
Collaborative development with git
KEY
Let's Git this Party Started: An Introduction to Git and GitHub
PPTX
Que nos espera a los ALM Dudes para el 2013?
PPTX
git and github-1.pptx
PPT
Git installation and configuration
PDF
Intro to Git & GitHub
PPT
Open up your platform with Open Source and GitHub
Beginner's Guide to Version Control with Git
Git-guidance for beginner- IT support.pptx.pptx
Git-guidance for beginner- IT support.pptx
Git One Day Training Notes
Learn Git - For Beginners and Intermediate levels
GIT from n00b
Github By Nyros Developer
Practical Git - NYC Code Camp
Mini-training: Let’s Git It!
The Basics of Open Source Collaboration With Git and GitHub
Git for folk who like GUIs
Git workshop
Collaborative development with git
Let's Git this Party Started: An Introduction to Git and GitHub
Que nos espera a los ALM Dudes para el 2013?
git and github-1.pptx
Git installation and configuration
Intro to Git & GitHub
Open up your platform with Open Source and GitHub

Enterprise git