SlideShare uma empresa Scribd logo
1 de 79
Baixar para ler offline
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

Mais conteúdo relacionado

Mais procurados

Git: A Getting Started Presentation
Git: A Getting Started PresentationGit: A Getting Started Presentation
Git: A Getting Started PresentationNap Ramirez
 
Introduction to GitHub
Introduction to GitHubIntroduction to GitHub
Introduction to GitHubNishan Bose
 
How we scaled git lab for a 30k employee company
How we scaled git lab for a 30k employee companyHow we scaled git lab for a 30k employee company
How we scaled git lab for a 30k employee companyMinqi Pan
 
Github Case Study By Amil Ali
Github Case Study By Amil AliGithub Case Study By Amil Ali
Github Case Study By Amil AliAmilAli1
 
Git Educated About Git - 20 Essential Commands
Git Educated About Git - 20 Essential CommandsGit Educated About Git - 20 Essential Commands
Git Educated About Git - 20 Essential CommandsJeremy Lindblom
 
Starting with Git & GitHub
Starting with Git & GitHubStarting with Git & GitHub
Starting with Git & GitHubNicolás Tourné
 
Git 101 tutorial presentation
Git 101 tutorial presentationGit 101 tutorial presentation
Git 101 tutorial presentationTerry Wang
 
Introduction to github slideshare
Introduction to github slideshareIntroduction to github slideshare
Introduction to github slideshareRakesh Sukumar
 
Introduction to git and Github
Introduction to git and GithubIntroduction to git and Github
Introduction to git and GithubWycliff1
 
How Git and Gerrit make you more productive
How Git and Gerrit make you more productiveHow Git and Gerrit make you more productive
How Git and Gerrit make you more productiveKarsten Dambekalns
 
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
 
Git Tutorial For Beginners | What is Git and GitHub? | DevOps Tools | DevOps ...
Git Tutorial For Beginners | What is Git and GitHub? | DevOps Tools | DevOps ...Git Tutorial For Beginners | What is Git and GitHub? | DevOps Tools | DevOps ...
Git Tutorial For Beginners | What is Git and GitHub? | DevOps Tools | DevOps ...Simplilearn
 
Git Tutorial I
Git Tutorial IGit Tutorial I
Git Tutorial IJim Yeh
 
Gerrit is Getting Native with RPM, Deb and Docker
Gerrit is Getting Native with RPM, Deb and DockerGerrit is Getting Native with RPM, Deb and Docker
Gerrit is Getting Native with RPM, Deb and DockerLuca Milanesio
 
GitLab as an Alternative Development Platform for Github.com
GitLab as an Alternative Development Platform for Github.comGitLab as an Alternative Development Platform for Github.com
GitLab as an Alternative Development Platform for Github.comB1 Systems GmbH
 

Mais procurados (20)

Github basics
Github basicsGithub basics
Github basics
 
Git: A Getting Started Presentation
Git: A Getting Started PresentationGit: A Getting Started Presentation
Git: A Getting Started Presentation
 
Introduction to GitHub
Introduction to GitHubIntroduction to GitHub
Introduction to GitHub
 
How we scaled git lab for a 30k employee company
How we scaled git lab for a 30k employee companyHow we scaled git lab for a 30k employee company
How we scaled git lab for a 30k employee company
 
Github Case Study By Amil Ali
Github Case Study By Amil AliGithub Case Study By Amil Ali
Github Case Study By Amil Ali
 
Git Educated About Git - 20 Essential Commands
Git Educated About Git - 20 Essential CommandsGit Educated About Git - 20 Essential Commands
Git Educated About Git - 20 Essential Commands
 
Starting with Git & GitHub
Starting with Git & GitHubStarting with Git & GitHub
Starting with Git & GitHub
 
Git 101 tutorial presentation
Git 101 tutorial presentationGit 101 tutorial presentation
Git 101 tutorial presentation
 
Introduction to github slideshare
Introduction to github slideshareIntroduction to github slideshare
Introduction to github slideshare
 
Introduction to git and Github
Introduction to git and GithubIntroduction to git and Github
Introduction to git and Github
 
How Git and Gerrit make you more productive
How Git and Gerrit make you more productiveHow Git and Gerrit make you more productive
How Git and Gerrit make you more productive
 
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
 
Git Tutorial For Beginners | What is Git and GitHub? | DevOps Tools | DevOps ...
Git Tutorial For Beginners | What is Git and GitHub? | DevOps Tools | DevOps ...Git Tutorial For Beginners | What is Git and GitHub? | DevOps Tools | DevOps ...
Git Tutorial For Beginners | What is Git and GitHub? | DevOps Tools | DevOps ...
 
Git and Github
Git and GithubGit and Github
Git and Github
 
Git and Github Session
Git and Github SessionGit and Github Session
Git and Github Session
 
Git training
Git trainingGit training
Git training
 
Git Tutorial I
Git Tutorial IGit Tutorial I
Git Tutorial I
 
Gerrit is Getting Native with RPM, Deb and Docker
Gerrit is Getting Native with RPM, Deb and DockerGerrit is Getting Native with RPM, Deb and Docker
Gerrit is Getting Native with RPM, Deb and Docker
 
Git Tutorial
Git TutorialGit Tutorial
Git Tutorial
 
GitLab as an Alternative Development Platform for Github.com
GitLab as an Alternative Development Platform for Github.comGitLab as an Alternative Development Platform for Github.com
GitLab as an Alternative Development Platform for Github.com
 

Destaque

EDA with SAPO Broker
EDA with SAPO BrokerEDA with SAPO Broker
EDA with SAPO BrokerPedro Melo
 
Perl Instruments
Perl InstrumentsPerl Instruments
Perl InstrumentsPedro Melo
 
Large-scale digitisation options at the Natural History Museum, London.
Large-scale digitisation options at the Natural History Museum, London.Large-scale digitisation options at the Natural History Museum, London.
Large-scale digitisation options at the Natural History Museum, London.Vince Smith
 

Destaque (6)

EDA with SAPO Broker
EDA with SAPO BrokerEDA with SAPO Broker
EDA with SAPO Broker
 
Perl Instruments
Perl InstrumentsPerl Instruments
Perl Instruments
 
Plack
PlackPlack
Plack
 
WTF is XMPP?
WTF is XMPP?WTF is XMPP?
WTF is XMPP?
 
Large-scale digitisation options at the Natural History Museum, London.
Large-scale digitisation options at the Natural History Museum, London.Large-scale digitisation options at the Natural History Museum, London.
Large-scale digitisation options at the Natural History Museum, London.
 
Git Internals
Git InternalsGit Internals
Git Internals
 

Semelhante a Enterprise git

Beginner's Guide to Version Control with Git
Beginner's Guide to Version Control with GitBeginner's Guide to Version Control with Git
Beginner's Guide to Version Control with GitRobert Lee-Cann
 
Git One Day Training Notes
Git One Day Training NotesGit One Day Training Notes
Git One Day Training Notesglen_a_smith
 
Learn Git - For Beginners and Intermediate levels
Learn Git - For Beginners and Intermediate levelsLearn Git - For Beginners and Intermediate levels
Learn Git - For Beginners and Intermediate levelsGorav Singal
 
Practical Git - NYC Code Camp
Practical Git - NYC Code CampPractical Git - NYC Code Camp
Practical Git - NYC Code CampChristopher Gomez
 
The Basics of Open Source Collaboration With Git and GitHub
The Basics of Open Source Collaboration With Git and GitHubThe Basics of Open Source Collaboration With Git and GitHub
The Basics of Open Source Collaboration With Git and GitHubBigBlueHat
 
Git for folk who like GUIs
Git for folk who like GUIsGit for folk who like GUIs
Git for folk who like GUIsTim Osborn
 
Collaborative development with git
Collaborative development with gitCollaborative development with git
Collaborative development with gitJoseluis Laso
 
Let's Git this Party Started: An Introduction to Git and GitHub
Let's Git this Party Started: An Introduction to Git and GitHubLet's Git this Party Started: An Introduction to Git and GitHub
Let's Git this Party Started: An Introduction to Git and GitHubKim Moir
 
Que nos espera a los ALM Dudes para el 2013?
Que nos espera a los ALM Dudes para el 2013?Que nos espera a los ALM Dudes para el 2013?
Que nos espera a los ALM Dudes para el 2013?Bruno Capuano
 
git and github-1.pptx
git and github-1.pptxgit and github-1.pptx
git and github-1.pptxtnscharishma
 
Git installation and configuration
Git installation and configurationGit installation and configuration
Git installation and configurationKishor Kumar
 
Open up your platform with Open Source and GitHub
Open up your platform with Open Source and GitHubOpen up your platform with Open Source and GitHub
Open up your platform with Open Source and GitHubScott Graham
 
Introduction to Git and Github
Introduction to Git and Github Introduction to Git and Github
Introduction to Git and Github Max Claus Nunes
 

Semelhante a Enterprise git (20)

Beginner's Guide to Version Control with Git
Beginner's Guide to Version Control with GitBeginner's Guide to Version Control with Git
Beginner's Guide to Version Control with Git
 
3 Git
3 Git3 Git
3 Git
 
Git One Day Training Notes
Git One Day Training NotesGit One Day Training Notes
Git One Day Training Notes
 
Learn Git - For Beginners and Intermediate levels
Learn Git - For Beginners and Intermediate levelsLearn Git - For Beginners and Intermediate levels
Learn Git - For Beginners and Intermediate levels
 
GIT from n00b
GIT from n00bGIT from n00b
GIT from n00b
 
Github By Nyros Developer
Github By Nyros DeveloperGithub By Nyros Developer
Github By Nyros Developer
 
Practical Git - NYC Code Camp
Practical Git - NYC Code CampPractical Git - NYC Code Camp
Practical Git - NYC Code Camp
 
Mini-training: Let’s Git It!
Mini-training: Let’s Git It!Mini-training: Let’s Git It!
Mini-training: Let’s Git It!
 
The Basics of Open Source Collaboration With Git and GitHub
The Basics of Open Source Collaboration With Git and GitHubThe Basics of Open Source Collaboration With Git and GitHub
The Basics of Open Source Collaboration With Git and GitHub
 
Git for folk who like GUIs
Git for folk who like GUIsGit for folk who like GUIs
Git for folk who like GUIs
 
Git workshop
Git workshopGit workshop
Git workshop
 
Collaborative development with git
Collaborative development with gitCollaborative development with git
Collaborative development with git
 
Let's Git this Party Started: An Introduction to Git and GitHub
Let's Git this Party Started: An Introduction to Git and GitHubLet's Git this Party Started: An Introduction to Git and GitHub
Let's Git this Party Started: An Introduction to Git and GitHub
 
Que nos espera a los ALM Dudes para el 2013?
Que nos espera a los ALM Dudes para el 2013?Que nos espera a los ALM Dudes para el 2013?
Que nos espera a los ALM Dudes para el 2013?
 
git and github-1.pptx
git and github-1.pptxgit and github-1.pptx
git and github-1.pptx
 
Git installation and configuration
Git installation and configurationGit installation and configuration
Git installation and configuration
 
Intro to Git & GitHub
Intro to Git & GitHubIntro to Git & GitHub
Intro to Git & GitHub
 
Open up your platform with Open Source and GitHub
Open up your platform with Open Source and GitHubOpen up your platform with Open Source and GitHub
Open up your platform with Open Source and GitHub
 
Introduction to Git and Github
Introduction to Git and GithubIntroduction to Git and Github
Introduction to Git and Github
 
Introduction to Git and Github
Introduction to Git and Github Introduction to Git and Github
Introduction to Git and Github
 

Enterprise git