True Git

Post on 23-Jan-2015

583 views 3 download

Tags:

description

 

Transcript of True Git

S T E F A N S A A S E N • S T A S H D E V E L O P M E N T M A N A G E R • A T L A S S I A N • @ s t e f a n s a a s e n

True GitTHE GREAT MIGRATION

TODO Show of hands

Picture with hands/lighter/concert

Source Control Management

SVN Git

Source Control Management

2011 2013 (projected) 2013 2015 (projected)

SVN Git

Source Control Management

2011 2013 (projected) 2013 2015 (projected)

20

78

SVN Git

Source Control Management

2011 2013 (projected) 2013 2015 (projected)

20

78

41

68

SVN Git

Source Control Management

2011 2013 (projected) 2013 2015 (projected)

20

78

41

68

49

70

SVN Git

Source Control Management

2011 2013 (projected) 2013 2015 (projected)

20

78

41

68

49

70 68

55

SVN Git

Why am I passionate about this?

Why am I passionate about this?

Why Git?

Branching & Merging

Branching & Mergingfast, cheap and simple

Branching & Mergingfast, cheap and simple

first class concept

Branching & Mergingfast, cheap and simple

first class concept

Foundation for new workflows

Speed

Speed

git log

git diffgit status

Speed

git bisect

git log

git diffgit status

git bisect

Bad

git bisect

Bad

Good (v2.7)

git bisect

Bad

Test

git bisect

Bad

Test

git bisect

Bad

Regression!

git bisect

Regression!

Fast graph traversalFast checkout

git bisect

Speed

git bisect

git log

git diffgit status

Enables new features

Improves basic features

Local commits

Local commits

Edit & Publish

Local commitsRewrite History

Edit & Publish

Local commitsRewrite History

Edit & Publish

Flexibility

Git does what you are doing today, only better

S V N

L A B E L T I T L E

GIT

S V N

L A B E L T I T L E

GIT

S V N

Existing workflows

L A B E L T I T L E

GIT

S V N

New ways of collaborating

Existing workflows

L A B E L T I T L E

GIT

S V N

New ways of collaborating

Existing workflows

New branchworkflows

L A B E L T I T L E

GIT

S V N

New ways of collaborating

Existing workflows

New branchworkflows

L A B E L T I T L E

GIT

S V N

New ways of collaborating

Existing workflows

New branchworkflows

L A B E L T I T L E

GIT

S V N

New ways of collaborating

Existing workflows

New branchworkflows

Release branching master

2.8

2.7

Release branching master

2.8

2.7

Bugfix

Release branching master

2.8

2.7

Bugfix

Release branching master

2.8

2.7

Bugfix

Release branching master

2.8

2.7

Bugfix

Release branching master

2.8

2.7

Bugfix

Git Workflows a-la-carte

N i c o l a P a o l u c c i

Rapid Agile Delivery

M a t t h e w W a t s o n

T h u r s d a y - 1 1 : 1 5 a m T h u r s d a y - 1 : 1 5 p m

So you’ve decided to migrate!

The process

1

2

3

Inception

Adoption

Conversion

Inception 1

• Is git suitable?

Inception 1

• Is git suitable?

• Test the conversion

Inception 1

• Is git suitable?

• Test the conversion

• Identify the repositories that need to be converted

Inception 1

• Is git suitable?

• Test the conversion

• Identify the repositories that need to be converted

• Identify the tools that need to be updated. CI, issue tracking, IDE, scripts and build tools, deployment tools

Inception 1

1

1

2

3

The process

Inception

Adoption

Conversion

Adoption 2

• You need to answer: “What’s in it for me”

Adoption 2

• You need to answer: “What’s in it for me”

• Make sure tooling is ready and can be used by everyone

Adoption 2

• You need to answer: “What’s in it for me”

• Make sure tooling is ready and can be used by everyone

• Identify the git champions - they will be thrilled to help

Adoption 2

• You need to answer: “What’s in it for me”

• Make sure tooling is ready and can be used by everyone

• Identify the git champions - they will be thrilled to help

• Don’t expect to win everyone over immediately

Adoption 2

2

Just text by itself, for impact.

2

1

2

3

The process

Inception

Adoption

Conversion

We’ve got you covered!

&Scripts Tutorial & Documentation

We’ve got you covered!

&Scripts Tutorial & Documentation

bit.ly/go-dvcs

git-svn

3

3Conversion - Preparation

jdeveloper = John Developer <jd@example.com>

Map Authors

3Conversion - Preparation

jdeveloper = John Developer <jd@example.com>

Map Authors

Identify SVN repository layout

/tags/trunk/branches

3Conversion - Preparation

git svn clone \ --authors-file=/authors.txt \ --trunk=/trunk \ --tags=/tags \ --branches=/branches

3Conversion - Initial Clone

git svn clone \ --authors-file=/authors.txt \ --trunk=/trunk \ --tags=/tags \ --branches=/branches

3Conversion - Initial Clone

?

3Conversion - Sync

3Conversion - Sync

git svn fetch

3Conversion - Sync

Infrastructure first 3

C I I s s u e s I D E

Infrastructure first 3

C I I s s u e s I D E

read-only

Infrastructure first 3

C I I s s u e s I D E

read-only

Infrastructure first 3

C I I s s u e s I D E

read-only

Sync every minute

• Cleanup branches

• Remove unused files

• Create git tags

• Remove commit metadata

3Conversion - Cleanup

• Cleanup branches

• Remove unused files

• Create git tags

• Remove commit metadata

3Conversion - Cleanup

3

C I I s s u e s I D E

read-only

Then your team 3

C I I s s u e s I D E

read-only

Then your team 3

C I I s s u e s I D E

read-only

Then your team 3

C I I s s u e s I D E

read-only

Other Tools?

SubGit

1

2

3

The process

Inception

Adoption

Conversion

Or are you?

Just text by itself, for impact.

Collaboration model?Branching model?

+

Enterprise

Centralized=+

Enterprise

Centralized=+

Enterprise

Builds

Metrics

Issues

Deployments

Workflows will change

Workflows will changefor the better

Workflows will changefor the better

but they don’t have to change on day one!

This happened in both Confluence and JIRA...

master

confluence-project-4.0

CONF-1234

From SVN like

master

confluence-project-4.0

CONF-1234

git cherry-pick bae6251

From SVN like

master

confluence-project-4.0

CONF-1234

git cherry-pick bae6251

From SVN like

master

confluence-project-4.0

CONF-1234

From SVN like

master

confluence-project-4.0

CONF-1234

From SVN like

master

confluence-project-4.1

To git branch based workflow

master

confluence-project-4.1

To git branch based workflow

master

confluence-project-4.1

CONF-2345

To git branch based workflow

master

confluence-project-4.1

CONF-2345

git merge confluence-project-4.1

To git branch based workflow

master

confluence-project-4.1

CONF-2345

To git branch based workflow

master

confluence-project-4.1

CONF-2345

git merge confluence-project-4.1

To git branch based workflow

Forks can be useful!

Sub-Teams

Forks can be useful!

Sub-Teams

Forks can be useful!

Contributions from outside of the team

Sub-Teams

Forks can be useful!

Conclusion

0

20

40

60

80

2011 2013 (projected) 2013 2015 (projected)

68

4941

20

55

706878

SVN Git

0

20

40

60

80

2011 2013 (projected) 2013 2015 (projected)

68

4941

20

55

706878

SVN Git

Subversion (58%) is being

threatened by Git (47%) for de facto leadership of the Version Control space. Z E R O T U R N A R O U N D D E V E L O P E R P R O D U C T I V I T Y R E P O R T 2 0 1 3

is here to stay

expands

migration is a solved problem

Thank you!

S T E F A N S A A S E N • S T A S H D E V E L O P M E N T M A N A G E R • A T L A S S I A N • @ s t e f a n s a a s e n