SlideShare a Scribd company logo
1 of 67
Download to read offline
. 
WWoorrkkiinngg wwiitthhmmuullttiippllee ggiitt rreeppoossiittoorriieess 
Julien Pivotto 
T-Dose, Eindhoven 
October 26, 2014
. 
wwhhooaammii 
JJuulliieenn PPiivvoottttoo 
• System administrator at inuits.eu 
• Git user for 5+ years 
• DevOps believer 
• Open-source defender since 2004 
• roidelapluie on twitter/github
. 
OOppss <<33 DDeevv 
• Infrastructure as Code 
▶ SCM all the things 
▶ Monitoring 
▶ Configuration 
▶ Application deployment 
• Taking part of software development 
▶ Understanding 
▶ Monitoring 
▶ High Availability 
▶ …
. 
MMee aanndd ggiitt 
• I first used subversion (10 years ago) 
• Private forges and sourceforge 
• 5 years later a lot of projects moved to git 
• The Puppet community also uses a lot git 
• Git/Hg are the de-facto standards in OS 
projects
. 
Git is a free and open source distributed version control system 
designed to handle everything from small to very large projects 
with speed and efficiency. 
Source: http://git-scm.com/
. 
ggiitt lloogg 
• Initiated in 2005 by Linus Torvalds 
• Replacement of closed-source BitKeeper 
• Created for the Linux Kernel development 
• Now used by thousands of projects
. 
ggiitt iiss ddiissttrriibbuutteedd 
• Everything can be done in local (exept 
pull&push) 
• Work with several remotes 
• Share code with anyone 
• No unique central repository 
• A lot of workflows possible
. 
BBrraanncchhiinngg aannddmmeerrggiinngg iiss eeaassyy 
• You can branch locally 
• Merging is easy and simple 
• You can squash commits
. 
HHooww ttoo aacccceessss aa rreeppoo 
• Locally (Local filesystems) 
• SSH 
• HTTP/HTTPs 
• Git protocol
. 
ggiitt iiss ooppeenn--ssoouurrccee 
• Published under GPL-2 
• Written in C 
• A lot of frontends/backends 
• A lot of libraries 
• A lot of hosting services 
• And a lot of users
. 
MMuullttiippllee ggiitt rreeppooss:: wwhhyy?? 
• Code isolation: plugins, libraries 
• Getting faster feedback from testing 
• Contributing back to upstream projects 
• Separate apps that are released together 
• Share code between projects
. 
MMuullttiippllee ggiitt rreeppooss uusseeccaasseess 
• Infrastructure as Code 
• Projects released together 
• Projects that embed external libraries 
• …
. 
git submodules
. 
ggiitt ssuubbmmoodduulleess 
• Built-in with git 
• Embeds external repositories in a 
subdirectory or your repo 
• Points these external repositories in a 
particular commit
. 
ggiitt ssuubbmmoodduulleess 
• Submodules act like traditional git 
repositories 
• Super repo contains a file with the 
submodules urls 
• Super repo contains objects that can be 
updated with commit hashes
. 
IInniittiiaattee ssuuppeerr--rreeppoo 
. 
$ git init . 
Initialized empty Git repository in /home/roidelapluie 
/super-repo/.git/ 
$ > README 
$ git add README 
$ git commit -m "Initial commit" 
[master (root-commit) b526be8] Initial commit 
1 file changed, 0 insertions(+), 0 deletions(-) 
create mode 100644 README 
.
. 
IInniittiiaattee ssuubbrreeppoo 
. 
$ git init . 
Initialized empty Git repository in /home/roidelapluie 
/subrepo/.git/ 
$ > README 
$ git add README 
$ git commit -m "Initial commit" 
[master (root-commit) 41e64b6] Initial commit 
1 file changed, 0 insertions(+), 0 deletions(-) 
create mode 100644 README 
.
. 
AAdddd ffiirrssttmmoodduullee iinn ppaarreenntt rreeppoo 
. 
$ git submodule add ../subrepo/ subrepo 
Cloning into 'subrepo'... 
done. 
$ git status 
On branch master 
Changes to be committed: 
(use "git reset HEAD <file>..." to unstage) 
. 
new file: .gitmodules 
new file: subrepo
. 
WWhhaatt jjuusstt hhaappppeenneedd?? 
• git created a .gitmodules file 
• It cloned the subrepo in a directory 
• It created a git object that points to the repo 
• That object contains the git revision
. 
..ggiittmmoodduulleess ffiillee 
. 
$ cat .gitmodules 
[submodule "subrepo"] 
. 
path = subrepo 
url = ../subrepo/ 
• Unique file for all the submodules 
• Only contains the path and the url 
• In this case, we use relative URL
. 
CCoommmmiittiinngg oouurr cchhaannggee 
. 
$ git commit -m "Add subrepo" 
[master 3251a63] Add subrepo 
2 files changed, 4 insertions(+) 
create mode 100644 .gitmodules 
create mode 160000 subrepo 
.
. 
CClloonniinngg tthhaatt ssuuppeerr rreeppoo 
. 
$ git clone /home/roidelapluie/super-repo/ . 
Cloning into '.'... 
done. 
$ ls subrepo/ 
$ git submodule init 
Submodule 'subrepo' (/home/roidelapluie/subrepo) 
registered for path 'subrepo' 
$ git submodule update 
Cloning into 'subrepo'... 
done. 
Submodule path 'subrepo': checked out '41e64b6bc0c97052 
1c296b9c5e6a0b9144778962' 
.
. 
SShhoorrccuutt ##11 
. 
$ git submodule init 
$ git submodule update 
. 
. 
$ git submodule update --init 
Submodule 'subrepo' (/home/roidelapluie/subrepo) 
registered for path 'subrepo' 
Cloning into 'subrepo'... 
done. 
Submodule path 'subrepo': checked out '41e64b6bc0c97052 
1c296b9c5e6a0b9144778962' 
.
. 
SShhoorrccuutt ##22 
. 
$ git clone /home/roidelapluie/super-repo/ . 
$ git submodule init 
$ git submodule update 
. 
. 
$ git clone --recurse-submodules /home/roidelapluie/ 
super-repo/ . 
Cloning into '.'... 
done. 
Submodule 'subrepo' (/home/roidelapluie/subrepo) 
registered for path 'subrepo' 
Cloning into 'subrepo'... 
done. 
Submodule path 'subrepo': checked out '41e64b6bc0c97052 
1c296b9c5e6a0b9144778962' 
.
. 
WWoorrkkiinngg iinn aa ssuubbmmoodduullee 
. 
$ cd subrepo 
$ > newfile 
$ git add newfile 
$ git commit -m "add newfile" 
[detached HEAD 6ee0e71] add newfile 
1 file changed, 0 insertions(+), 0 deletions(-) 
create mode 100644 newfile 
$ git push 
fatal: You are not currently on a branch. 
To push the history leading to the current (detached HEAD) 
state now, use 
. 
git push origin HEAD:<name-of-remote-branch>
. 
CChheecckkiinngg oouutt aa bbrraanncchh 
. 
$ git checkout master 
Warning: you are leaving 1 commit behind, not connected 
to any of your branches: 
6ee0e71 add newfile 
If you want to keep them by creating a new branch, this 
may be a good time to do so with: 
git branch new_branch_name 6ee0e71 
Switched to branch 'master' 
Your branch is up-to-date with 'origin/master'. 
.
. 
MMeerrggiinngg oouurr ccoommmmiitt 
. 
$ git merge 6ee0e71 
Updating 41e64b6..6ee0e71 
Fast-forward 
newfile | 0 
1 file changed, 0 insertions(+), 0 deletions(-) 
create mode 100644 newfile 
.
. 
PPuusshhiinngg oouurr ccoommmmiitt 
. 
$ git push 
Counting objects: 2, done. 
Delta compression using up to 8 threads. 
Compressing objects: 100% (2/2), done. 
Writing objects: 100% (2/2), 247 bytes | 0 bytes/s, done. 
Total 2 (delta 0), reused 0 (delta 0) 
To /home/roidelapluie/subrepo 
. 
41e64b6..6ee0e71 master -> master
. 
PPuusshhiinngg oouurr ccoommmmiitt 
. 
$ date > newfile 
$ git commit -am "update newfile" 
[master 8a56806] update newfile 
1 file changed, 1 insertion(+) 
$ git push 
Counting objects: 3, done. 
Delta compression using up to 8 threads. 
Compressing objects: 100% (2/2), done. 
Writing objects: 100% (3/3), 310 bytes | 0 bytes/s, done. 
Total 3 (delta 0), reused 0 (delta 0) 
To /home/roidelapluie/subrepo 
. 
6ee0e71..8a56806 master -> master
. 
LLeett''ss rreewwiinndd.... 
• A submodule not attached to a branch 
▶ Because submodules are referenced by their commit hash 
only 
▶ It is called the DETACHED HEAD 
• How to push then? 
▶ The easy/safe option is to checkout a branch 
• You only need to do that once
. 
ggiitt ssuubbmmoodduullee ffoorreeaacchh 
• git submodule foreach allow you to run a 
command on each repo 
▶ git submodule foreach git checkout master 
▶ git submodule foreach ls 
▶ git submodule foreach git commit -am "foo"
. 
MMeeaannwwhhiillee,, oonn tthhee ssuuppeerr--pprroojjeecctt…… 
. 
$ git status 
On branch master 
Changes not staged for commit: 
(use "git add <file>..." to update what will be 
committed) 
(use "git checkout -- <file>..." to discard changes in 
working directory) 
. 
modified: subrepo (new commits) 
no changes added to commit (use "git add" and/or "git 
commit -a")
. 
UUppddaattee aa ssuubbrreeppoo 
. 
$ git commit -am "update subrepo" 
[master 731626b] update subrepo 
1 file changed, 1 insertion(+), 1 deletion(-) 
.
. 
LLooggss 
. 
$ git log -p --submodule=log subrepo/ 
commit 731626bc53d8c248647443b4c0523d96d316cd24 
Author: Julien Pivotto <roidelapluie@inuits.eu> 
Date: Sat Oct 25 22:26:56 2014 +0200 
. 
update subrepo 
Submodule subrepo 41e64b6..01c1b9c: 
> work on newfile 
> update newfile 
> add newfile
. 
CChhaannggee aa ssuubbmmoodduulleess UURRLL 
• Edit .gitmodules and commit the file 
• Run git submodule sync 
• Now the submodule will use the new URL
. 
ggiitt ssuubbmmoodduullee ----rreeccuurrssiivvee 
• Run commands recursively 
• You can get multiple levels of submodules 
• But you add complexity 
▶ Each level is 1 more commit you need to write 
▶ Playing with remote urls becomes tricky of you work with 
remotes
. 
SSuubbmmoodduulleess iinntteeggrraattiioonn 
• Integrated in git, standard 
• Integrated in CI tools (Jenkins) 
• Nothing specific needed for pulling 
• Need to checkout the submodules after 
pulling
. 
SSuubbmmoodduulleess iinn GGeerrrriitt 
• Gerrit integrates submodules 
• It can create commits in "super-repo" if a 
code change is merged 
• Not a perfect way of doing if changes in two 
repo's are depending of each other
. 
SSuubbmmoodduulleess iinn GGeerrrriitt 
• Gerrit is integrated in CI tools 
• Gerrit allows fine tuning ACL 
• Gerrit code reviews with submodules 
changes don't display changes in the 
submodules
. 
SSuubbmmoodduulleess pprrooss aanndd ccoonnss 
 Each commit in submodule is not in 
super-repo 
 It is easy to rollback by accident a 
submodule 
 Getting logs is not easy 
 You can forget to update super-repo 
 Submodules are not attached to a branch
. 
SSuubbmmoodduulleess pprrooss aanndd ccoonnss 
+ Built-in 
+ Can use relative urls 
+ You can control the version of the 
submodules 
+ Supported by many tools 
+ Easy rollbacks of submodules 
+ git bissect works (on the super repo)
. 
gitslave a.k.a. gits
. 
ggiittssllaavvee 
• First public release in 2010 
• Wrapper around git 
• gits can be used in place of git 
• Run each git commands in each subrepos
. 
IInniittiiaattee ggiittss 
. 
$ git init . 
Initialized empty Git repository in /home/roidelapluie/ 
superrepo/.git/ 
$ gits prepare 
[master (root-commit) 594c492] gits creating .gitslave 
1 file changed, 0 insertions(+), 0 deletions(-) 
create mode 100644 .gitslave 
.
. 
AAdddd aa ggiitt rreeppoo 
. 
$ gits attach /home/roidelapluie/subrepo/ subrepo 
Cloning into 'subrepo'... 
done. 
[master 926321f] gits adding /home/roidelapluie/ 
subrepo/ subrepo 
2 files changed, 2 insertions(+) 
create mode 100644 .gitignore 
$ cat .gitslave 
/home/roidelapluie/subrepo/ subrepo 
.
. 
CClloonniinngg aa rreeppoo 
. 
$ gits clone ../superrepo/ . 
Cloning into '.'... 
done. 
Cloning into 'subrepo'... 
done. 
.
. 
WWoorrkkiinngg iinn ssuubbmmoodduulleess 
. 
$ cd subrepo 
$ date  newfile 
$ git add newfile 
$ gits commit -m Work on newfile 
On: subrepo: 
[master 1230de3] Work on newfile 
. 
1 file changed, 1 insertion(+), 1 deletion(-) 
On: (super-repo): 
On branch master 
Your branch is up-to-date with 'origin/master'. 
nothing to commit, working directory clean
. 
PPuusshhiinngg cchhaannggeess 
. 
$ gits push 
On: subrepo: 
To /home/roidelapluie/subrepo/ 
. 
fbcf73c..1230de3 master - master 
On: (super-repo): 
Everything up-to-date
. 
PPuulllliinngg cchhaannggeess 
. 
$ gits pull 
On: (super-repo), subrepo: 
Already up-to-date. 
.
. 
ggiitt ssllaavvee wwoorrkkffllooww 
• Subrepos are always attached to a branch 
• You can work within them normally 
• Run almost any git command with gits
. 
PPeerrffoorrmmaannccee 
• gits --parallel 8: run 8 parallel git commands 
• No extra commit in the super repository 
• Close to traditional git workflow
. 
AA bbrraanncchhiinngg aapppprrooaacchh 
• Use gits branch and gits checkout to switch 
between branches 
• All the repositories will switch branches (e.g 
1.0, 1.1) 
• Easy merge with gits merge 
• Avoid upstream traditional branch names
. 
ggiittss oouuttppuutt 
• gits will simplify the output of git 
commands 
• It will group the repos by output 
• Easier to see the status, the remotes, etc
. 
PPrrooss aanndd ccoonnss ooff ggiittssllaavvee 
 Not integrated in tools 
 Requires an additional binary 
 Not integrated in git 
 Hard to rollback on every repositories
. 
PPrrooss aanndd ccoonnss ooff ggiittssllaavvee 
+ Close to git workflow 
+ Less error-prone 
+ Use traditional git commands 
+ Every git push arrives in the repo
. 
MMiittiiggeeaattee ggiittssllaavveess'' iissssuueess 
• Use git hooks to trigger tests on CI 
▶ Polling SCM does not scale anyway 
▶ Use the Quite period feature 
• Use CI to add the same tag in each 
repository 
▶ Rollback to a tag, not a commit 
▶ Add a tag at each commit
. 
Additional tips
. 
UUssee SSSSHH ssoocckkeettss 
. 
$ cat .ssh/config 
Host githost 
. 
controlmaster auto 
controlpath /tmp/ssh-%r@%h:%p 
ControlPersist 300 
• Use only one SSH connection 
• Do not disconnect SSH
. 
FFiinndd tthhee ttaagg ooff aa ccoommmmiitt 
. 
$ git name-rev --name-only 106cb38dd0bc5ea2d2d0adef0b40 
06bd61884e42 
remotes/origin/8.5.2~1 
.
. 
ggiitt aauuttooccoorrrreecctt 
. 
$ git config help.autocorrect 10 
$ git pusk 
WARNING: You called a Git command named 'pusk', which does not Continuing under the assumption that you meant 'push' 
in 1.0 seconds automatically... 
.
. 
UUssee ggiitt hhooookkss 
• Multiple repositories = a lot of pull 
• Jenkins pulling X repos X times every 5 
minutes is a bad idea 
• Git hooks to the resue 
• Reduce load on Jenkins and the git server 
• Reduce the time before Jenkins launches 
builds
. 
GGPPGG--SSiiggnn yyoouurr ccoommmmiittss 
• git commit -S 
• Sign PR, merge commits 
• Do not sign every commit (then it becomes 
useless)
. 
KKeeeeppiinnggmmuullttiippllee rreemmootteess iinn ssyynncc 
• git remote set-url --add 
• Pull  push will ose both urls
. 
HHoommeewwoorrkk 
• Git subtree (also built-in) 
• Repo (from Android) 
• gr 
• …
. 
CCoonncclluussiioonnss 
• Git is an awesome, extandable tool 
• There are several ways to manage multiple 
git repositories 
• Working with multiple repos is easy 
• You have to learn tools anyway 
• Experiment them and pick one :-)
. 
TThhaannkk yyoouu 
Any question?
. 
CCoonnttaacctt 
Julien Pivotto 
julien@inuits.eu 
@roidelapluie 
INUITS bvba 
Belgium 
+32 473 441 636 
https://inuits.eu

More Related Content

What's hot

Git Started With Git
Git Started With GitGit Started With Git
Git Started With GitNick Quaranto
 
初心者 Git 上手攻略
初心者 Git 上手攻略初心者 Git 上手攻略
初心者 Git 上手攻略Lucien Lee
 
Git Tutorial I
Git Tutorial IGit Tutorial I
Git Tutorial IJim Yeh
 
Git - Basic Crash Course
Git - Basic Crash CourseGit - Basic Crash Course
Git - Basic Crash CourseNilay Binjola
 
Advanced Git Presentation By Swawibe
Advanced Git Presentation By SwawibeAdvanced Git Presentation By Swawibe
Advanced Git Presentation By SwawibeMd Swawibe Ul Alam
 
Introduction to git flow
Introduction to git flowIntroduction to git flow
Introduction to git flowKnoldus Inc.
 
社内Git勉強会向け資料
社内Git勉強会向け資料社内Git勉強会向け資料
社内Git勉強会向け資料Hiroki Saiki
 
Git flow for daily use
Git flow for daily useGit flow for daily use
Git flow for daily useMediacurrent
 
Pakalpojumu sniedzēju atlase | Daudzdzīvokļu māju energoefektivitātes programma
Pakalpojumu sniedzēju atlase | Daudzdzīvokļu māju energoefektivitātes programmaPakalpojumu sniedzēju atlase | Daudzdzīvokļu māju energoefektivitātes programma
Pakalpojumu sniedzēju atlase | Daudzdzīvokļu māju energoefektivitātes programmaALTUM
 
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
 
Intro to git and git hub
Intro to git and git hubIntro to git and git hub
Intro to git and git hubJasleenSondhi
 
Workshop git para iniciantes
Workshop git para iniciantesWorkshop git para iniciantes
Workshop git para iniciantesPaula Santana
 
デザイナのためのGit入門
デザイナのためのGit入門デザイナのためのGit入門
デザイナのためのGit入門dsuke Takaoka
 
Case Study: Migration to GitLab (from Bitbucket) at AppsFlyer
Case Study: Migration to GitLab (from Bitbucket) at AppsFlyerCase Study: Migration to GitLab (from Bitbucket) at AppsFlyer
Case Study: Migration to GitLab (from Bitbucket) at AppsFlyerNoa Harel
 

What's hot (20)

Git submodule
Git submoduleGit submodule
Git submodule
 
Git Started With Git
Git Started With GitGit Started With Git
Git Started With Git
 
Git flow
Git flowGit flow
Git flow
 
Git & GitLab
Git & GitLabGit & GitLab
Git & GitLab
 
Git (実践入門編)
Git (実践入門編)Git (実践入門編)
Git (実践入門編)
 
初心者 Git 上手攻略
初心者 Git 上手攻略初心者 Git 上手攻略
初心者 Git 上手攻略
 
Git Tutorial I
Git Tutorial IGit Tutorial I
Git Tutorial I
 
Introdução ao Git
Introdução ao GitIntrodução ao Git
Introdução ao Git
 
Git - Basic Crash Course
Git - Basic Crash CourseGit - Basic Crash Course
Git - Basic Crash Course
 
Intro to Git, GitHub, and BitBucket
Intro to Git, GitHub, and BitBucketIntro to Git, GitHub, and BitBucket
Intro to Git, GitHub, and BitBucket
 
Advanced Git Presentation By Swawibe
Advanced Git Presentation By SwawibeAdvanced Git Presentation By Swawibe
Advanced Git Presentation By Swawibe
 
Introduction to git flow
Introduction to git flowIntroduction to git flow
Introduction to git flow
 
社内Git勉強会向け資料
社内Git勉強会向け資料社内Git勉強会向け資料
社内Git勉強会向け資料
 
Git flow for daily use
Git flow for daily useGit flow for daily use
Git flow for daily use
 
Pakalpojumu sniedzēju atlase | Daudzdzīvokļu māju energoefektivitātes programma
Pakalpojumu sniedzēju atlase | Daudzdzīvokļu māju energoefektivitātes programmaPakalpojumu sniedzēju atlase | Daudzdzīvokļu māju energoefektivitātes programma
Pakalpojumu sniedzēju atlase | Daudzdzīvokļu māju energoefektivitātes programma
 
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
 
Intro to git and git hub
Intro to git and git hubIntro to git and git hub
Intro to git and git hub
 
Workshop git para iniciantes
Workshop git para iniciantesWorkshop git para iniciantes
Workshop git para iniciantes
 
デザイナのためのGit入門
デザイナのためのGit入門デザイナのためのGit入門
デザイナのためのGit入門
 
Case Study: Migration to GitLab (from Bitbucket) at AppsFlyer
Case Study: Migration to GitLab (from Bitbucket) at AppsFlyerCase Study: Migration to GitLab (from Bitbucket) at AppsFlyer
Case Study: Migration to GitLab (from Bitbucket) at AppsFlyer
 

Viewers also liked

Avoid Git Bloat and Submodule Hell with Git Fusion
Avoid Git Bloat and Submodule Hell with Git FusionAvoid Git Bloat and Submodule Hell with Git Fusion
Avoid Git Bloat and Submodule Hell with Git FusionPerforce
 
Dependencies Managers in C/C++. Using stdcpp 2014
Dependencies Managers in C/C++. Using stdcpp 2014Dependencies Managers in C/C++. Using stdcpp 2014
Dependencies Managers in C/C++. Using stdcpp 2014biicode
 
Toiminta ja laatujärjestelmät + työsuojelu 20160615
Toiminta  ja laatujärjestelmät + työsuojelu 20160615Toiminta  ja laatujärjestelmät + työsuojelu 20160615
Toiminta ja laatujärjestelmät + työsuojelu 20160615Eija Kupi
 
Advanced Git: Functionality and Features
Advanced Git: Functionality and FeaturesAdvanced Git: Functionality and Features
Advanced Git: Functionality and FeaturesBrent Laster
 
What Is Iso/iec 15504
What Is Iso/iec 15504What Is Iso/iec 15504
What Is Iso/iec 15504pax_isp
 
Git: An introduction of plumbing and porcelain commands
Git: An introduction of plumbing and porcelain commandsGit: An introduction of plumbing and porcelain commands
Git: An introduction of plumbing and porcelain commandsth507
 
System webpack-jspm
System webpack-jspmSystem webpack-jspm
System webpack-jspmJesse Warden
 
New Programming Style of Java
New Programming Style of JavaNew Programming Style of Java
New Programming Style of JavaYuichi Sakuraba
 
Getting Git Right
Getting Git RightGetting Git Right
Getting Git RightSven Peters
 
ESB vs API management
ESB vs API managementESB vs API management
ESB vs API managementAdroitLogic
 
Jenkins and Chef: Infrastructure CI and Automated Deployment
Jenkins and Chef: Infrastructure CI and Automated DeploymentJenkins and Chef: Infrastructure CI and Automated Deployment
Jenkins and Chef: Infrastructure CI and Automated DeploymentDan Stine
 
Android Development: The Basics
Android Development: The BasicsAndroid Development: The Basics
Android Development: The BasicsMike Desjardins
 
What is tackled in the Java EE Security API (Java EE 8)
What is tackled in the Java EE Security API (Java EE 8)What is tackled in the Java EE Security API (Java EE 8)
What is tackled in the Java EE Security API (Java EE 8)Rudy De Busscher
 
Boost Your Teaching with Google Tools
Boost Your Teaching with Google ToolsBoost Your Teaching with Google Tools
Boost Your Teaching with Google ToolsRafael Scapin, Ph.D.
 
State of the Jenkins Automation
State of the Jenkins AutomationState of the Jenkins Automation
State of the Jenkins AutomationJulien Pivotto
 

Viewers also liked (20)

Linux HA anno 2014
Linux HA anno 2014Linux HA anno 2014
Linux HA anno 2014
 
Git Submodules
Git SubmodulesGit Submodules
Git Submodules
 
Avoid Git Bloat and Submodule Hell with Git Fusion
Avoid Git Bloat and Submodule Hell with Git FusionAvoid Git Bloat and Submodule Hell with Git Fusion
Avoid Git Bloat and Submodule Hell with Git Fusion
 
Dependencies Managers in C/C++. Using stdcpp 2014
Dependencies Managers in C/C++. Using stdcpp 2014Dependencies Managers in C/C++. Using stdcpp 2014
Dependencies Managers in C/C++. Using stdcpp 2014
 
Toiminta ja laatujärjestelmät + työsuojelu 20160615
Toiminta  ja laatujärjestelmät + työsuojelu 20160615Toiminta  ja laatujärjestelmät + työsuojelu 20160615
Toiminta ja laatujärjestelmät + työsuojelu 20160615
 
Advanced Git: Functionality and Features
Advanced Git: Functionality and FeaturesAdvanced Git: Functionality and Features
Advanced Git: Functionality and Features
 
Git Rebase vs Merge
Git Rebase vs MergeGit Rebase vs Merge
Git Rebase vs Merge
 
What Is Iso/iec 15504
What Is Iso/iec 15504What Is Iso/iec 15504
What Is Iso/iec 15504
 
Git: An introduction of plumbing and porcelain commands
Git: An introduction of plumbing and porcelain commandsGit: An introduction of plumbing and porcelain commands
Git: An introduction of plumbing and porcelain commands
 
System webpack-jspm
System webpack-jspmSystem webpack-jspm
System webpack-jspm
 
New Programming Style of Java
New Programming Style of JavaNew Programming Style of Java
New Programming Style of Java
 
Getting Git Right
Getting Git RightGetting Git Right
Getting Git Right
 
File systems for Embedded Linux
File systems for Embedded LinuxFile systems for Embedded Linux
File systems for Embedded Linux
 
ESB vs API management
ESB vs API managementESB vs API management
ESB vs API management
 
Jenkins and Chef: Infrastructure CI and Automated Deployment
Jenkins and Chef: Infrastructure CI and Automated DeploymentJenkins and Chef: Infrastructure CI and Automated Deployment
Jenkins and Chef: Infrastructure CI and Automated Deployment
 
Android Development: The Basics
Android Development: The BasicsAndroid Development: The Basics
Android Development: The Basics
 
Recycling
RecyclingRecycling
Recycling
 
What is tackled in the Java EE Security API (Java EE 8)
What is tackled in the Java EE Security API (Java EE 8)What is tackled in the Java EE Security API (Java EE 8)
What is tackled in the Java EE Security API (Java EE 8)
 
Boost Your Teaching with Google Tools
Boost Your Teaching with Google ToolsBoost Your Teaching with Google Tools
Boost Your Teaching with Google Tools
 
State of the Jenkins Automation
State of the Jenkins AutomationState of the Jenkins Automation
State of the Jenkins Automation
 

Similar to Working with multiple git repositories

Git and git workflow best practice
Git and git workflow best practiceGit and git workflow best practice
Git and git workflow best practiceMajid Hosseini
 
Git One Day Training Notes
Git One Day Training NotesGit One Day Training Notes
Git One Day Training Notesglen_a_smith
 
Introduction to Git for Artists
Introduction to Git for ArtistsIntroduction to Git for Artists
Introduction to Git for ArtistsDavid Newbury
 
Git installation and configuration
Git installation and configurationGit installation and configuration
Git installation and configurationKishor Kumar
 
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
 
Luis atencio on_git
Luis atencio on_gitLuis atencio on_git
Luis atencio on_gitLuis Atencio
 
Introduction to Git and Github
Introduction to Git and Github Introduction to Git and Github
Introduction to Git and Github Max Claus Nunes
 
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_training_SoftServeBulgaria2016
GIT_training_SoftServeBulgaria2016GIT_training_SoftServeBulgaria2016
GIT_training_SoftServeBulgaria2016Peter Denev
 
The Fundamentals of Git
The Fundamentals of GitThe Fundamentals of Git
The Fundamentals of GitDivineOmega
 
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 and Github workshop GDSC MLRITM
Git and Github  workshop GDSC MLRITMGit and Github  workshop GDSC MLRITM
Git and Github workshop GDSC MLRITMgdsc13
 
Git Introductive
Git IntroductiveGit Introductive
Git IntroductiveAdham Saad
 
Version control git day03
Version control   git day03Version control   git day03
Version control git day03Gourav Varma
 

Similar to Working with multiple git repositories (20)

Git github
Git githubGit github
Git github
 
Git and git workflow best practice
Git and git workflow best practiceGit and git workflow best practice
Git and git workflow best practice
 
Git One Day Training Notes
Git One Day Training NotesGit One Day Training Notes
Git One Day Training Notes
 
Introduction to Git for Artists
Introduction to Git for ArtistsIntroduction to Git for Artists
Introduction to Git for Artists
 
Git installation and configuration
Git installation and configurationGit installation and configuration
Git installation and configuration
 
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
 
Luis atencio on_git
Luis atencio on_gitLuis atencio on_git
Luis atencio on_git
 
Introduction to Git and Github
Introduction to Git and Github Introduction to Git and Github
Introduction to Git and Github
 
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
 
GIT_training_SoftServeBulgaria2016
GIT_training_SoftServeBulgaria2016GIT_training_SoftServeBulgaria2016
GIT_training_SoftServeBulgaria2016
 
Git tips and tricks
Git   tips and tricksGit   tips and tricks
Git tips and tricks
 
Git 101
Git 101Git 101
Git 101
 
The Fundamentals of Git
The Fundamentals of GitThe Fundamentals of Git
The Fundamentals of Git
 
Mini git tutorial
Mini git tutorialMini git tutorial
Mini git tutorial
 
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 and Github workshop GDSC MLRITM
Git and Github  workshop GDSC MLRITMGit and Github  workshop GDSC MLRITM
Git and Github workshop GDSC MLRITM
 
Git Introductive
Git IntroductiveGit Introductive
Git Introductive
 
Git training v10
Git training v10Git training v10
Git training v10
 
Version control git day03
Version control   git day03Version control   git day03
Version control git day03
 
Git & Github
Git & GithubGit & Github
Git & Github
 

More from Julien Pivotto

What's New in Prometheus and Its Ecosystem
What's New in Prometheus and Its EcosystemWhat's New in Prometheus and Its Ecosystem
What's New in Prometheus and Its EcosystemJulien Pivotto
 
Prometheus: What is is, what is new, what is coming
Prometheus: What is is, what is new, what is comingPrometheus: What is is, what is new, what is coming
Prometheus: What is is, what is new, what is comingJulien Pivotto
 
What's new in Prometheus?
What's new in Prometheus?What's new in Prometheus?
What's new in Prometheus?Julien Pivotto
 
Introduction to Grafana Loki
Introduction to Grafana LokiIntroduction to Grafana Loki
Introduction to Grafana LokiJulien Pivotto
 
Why you should revisit mgmt
Why you should revisit mgmtWhy you should revisit mgmt
Why you should revisit mgmtJulien Pivotto
 
Observing the HashiCorp Ecosystem From Prometheus
Observing the HashiCorp Ecosystem From PrometheusObserving the HashiCorp Ecosystem From Prometheus
Observing the HashiCorp Ecosystem From PrometheusJulien Pivotto
 
Monitoring in a fast-changing world with Prometheus
Monitoring in a fast-changing world with PrometheusMonitoring in a fast-changing world with Prometheus
Monitoring in a fast-changing world with PrometheusJulien Pivotto
 
5 tips for Prometheus Service Discovery
5 tips for Prometheus Service Discovery5 tips for Prometheus Service Discovery
5 tips for Prometheus Service DiscoveryJulien Pivotto
 
Prometheus and TLS - an Introduction
Prometheus and TLS - an IntroductionPrometheus and TLS - an Introduction
Prometheus and TLS - an IntroductionJulien Pivotto
 
Powerful graphs in Grafana
Powerful graphs in GrafanaPowerful graphs in Grafana
Powerful graphs in GrafanaJulien Pivotto
 
HAProxy as Egress Controller
HAProxy as Egress ControllerHAProxy as Egress Controller
HAProxy as Egress ControllerJulien Pivotto
 
Improved alerting with Prometheus and Alertmanager
Improved alerting with Prometheus and AlertmanagerImproved alerting with Prometheus and Alertmanager
Improved alerting with Prometheus and AlertmanagerJulien Pivotto
 
SIngle Sign On with Keycloak
SIngle Sign On with KeycloakSIngle Sign On with Keycloak
SIngle Sign On with KeycloakJulien Pivotto
 
Monitoring as an entry point for collaboration
Monitoring as an entry point for collaborationMonitoring as an entry point for collaboration
Monitoring as an entry point for collaborationJulien Pivotto
 
Incident Resolution as Code
Incident Resolution as CodeIncident Resolution as Code
Incident Resolution as CodeJulien Pivotto
 
Monitor your CentOS stack with Prometheus
Monitor your CentOS stack with PrometheusMonitor your CentOS stack with Prometheus
Monitor your CentOS stack with PrometheusJulien Pivotto
 
Monitor your CentOS stack with Prometheus
Monitor your CentOS stack with PrometheusMonitor your CentOS stack with Prometheus
Monitor your CentOS stack with PrometheusJulien Pivotto
 
An introduction to Ansible
An introduction to AnsibleAn introduction to Ansible
An introduction to AnsibleJulien Pivotto
 

More from Julien Pivotto (20)

The O11y Toolkit
The O11y ToolkitThe O11y Toolkit
The O11y Toolkit
 
What's New in Prometheus and Its Ecosystem
What's New in Prometheus and Its EcosystemWhat's New in Prometheus and Its Ecosystem
What's New in Prometheus and Its Ecosystem
 
Prometheus: What is is, what is new, what is coming
Prometheus: What is is, what is new, what is comingPrometheus: What is is, what is new, what is coming
Prometheus: What is is, what is new, what is coming
 
What's new in Prometheus?
What's new in Prometheus?What's new in Prometheus?
What's new in Prometheus?
 
Introduction to Grafana Loki
Introduction to Grafana LokiIntroduction to Grafana Loki
Introduction to Grafana Loki
 
Why you should revisit mgmt
Why you should revisit mgmtWhy you should revisit mgmt
Why you should revisit mgmt
 
Observing the HashiCorp Ecosystem From Prometheus
Observing the HashiCorp Ecosystem From PrometheusObserving the HashiCorp Ecosystem From Prometheus
Observing the HashiCorp Ecosystem From Prometheus
 
Monitoring in a fast-changing world with Prometheus
Monitoring in a fast-changing world with PrometheusMonitoring in a fast-changing world with Prometheus
Monitoring in a fast-changing world with Prometheus
 
5 tips for Prometheus Service Discovery
5 tips for Prometheus Service Discovery5 tips for Prometheus Service Discovery
5 tips for Prometheus Service Discovery
 
Prometheus and TLS - an Introduction
Prometheus and TLS - an IntroductionPrometheus and TLS - an Introduction
Prometheus and TLS - an Introduction
 
Powerful graphs in Grafana
Powerful graphs in GrafanaPowerful graphs in Grafana
Powerful graphs in Grafana
 
YAML Magic
YAML MagicYAML Magic
YAML Magic
 
HAProxy as Egress Controller
HAProxy as Egress ControllerHAProxy as Egress Controller
HAProxy as Egress Controller
 
Improved alerting with Prometheus and Alertmanager
Improved alerting with Prometheus and AlertmanagerImproved alerting with Prometheus and Alertmanager
Improved alerting with Prometheus and Alertmanager
 
SIngle Sign On with Keycloak
SIngle Sign On with KeycloakSIngle Sign On with Keycloak
SIngle Sign On with Keycloak
 
Monitoring as an entry point for collaboration
Monitoring as an entry point for collaborationMonitoring as an entry point for collaboration
Monitoring as an entry point for collaboration
 
Incident Resolution as Code
Incident Resolution as CodeIncident Resolution as Code
Incident Resolution as Code
 
Monitor your CentOS stack with Prometheus
Monitor your CentOS stack with PrometheusMonitor your CentOS stack with Prometheus
Monitor your CentOS stack with Prometheus
 
Monitor your CentOS stack with Prometheus
Monitor your CentOS stack with PrometheusMonitor your CentOS stack with Prometheus
Monitor your CentOS stack with Prometheus
 
An introduction to Ansible
An introduction to AnsibleAn introduction to Ansible
An introduction to Ansible
 

Recently uploaded

Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
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
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...HostedbyConfluent
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
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
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
Google AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGGoogle AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGSujit Pal
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 

Recently uploaded (20)

Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
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
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 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
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Google AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGGoogle AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAG
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 

Working with multiple git repositories

  • 1. . WWoorrkkiinngg wwiitthhmmuullttiippllee ggiitt rreeppoossiittoorriieess Julien Pivotto T-Dose, Eindhoven October 26, 2014
  • 2. . wwhhooaammii JJuulliieenn PPiivvoottttoo • System administrator at inuits.eu • Git user for 5+ years • DevOps believer • Open-source defender since 2004 • roidelapluie on twitter/github
  • 3. . OOppss <<33 DDeevv • Infrastructure as Code ▶ SCM all the things ▶ Monitoring ▶ Configuration ▶ Application deployment • Taking part of software development ▶ Understanding ▶ Monitoring ▶ High Availability ▶ …
  • 4. . MMee aanndd ggiitt • I first used subversion (10 years ago) • Private forges and sourceforge • 5 years later a lot of projects moved to git • The Puppet community also uses a lot git • Git/Hg are the de-facto standards in OS projects
  • 5. . Git is a free and open source distributed version control system designed to handle everything from small to very large projects with speed and efficiency. Source: http://git-scm.com/
  • 6. . ggiitt lloogg • Initiated in 2005 by Linus Torvalds • Replacement of closed-source BitKeeper • Created for the Linux Kernel development • Now used by thousands of projects
  • 7. . ggiitt iiss ddiissttrriibbuutteedd • Everything can be done in local (exept pull&push) • Work with several remotes • Share code with anyone • No unique central repository • A lot of workflows possible
  • 8. . BBrraanncchhiinngg aannddmmeerrggiinngg iiss eeaassyy • You can branch locally • Merging is easy and simple • You can squash commits
  • 9. . HHooww ttoo aacccceessss aa rreeppoo • Locally (Local filesystems) • SSH • HTTP/HTTPs • Git protocol
  • 10. . ggiitt iiss ooppeenn--ssoouurrccee • Published under GPL-2 • Written in C • A lot of frontends/backends • A lot of libraries • A lot of hosting services • And a lot of users
  • 11. . MMuullttiippllee ggiitt rreeppooss:: wwhhyy?? • Code isolation: plugins, libraries • Getting faster feedback from testing • Contributing back to upstream projects • Separate apps that are released together • Share code between projects
  • 12. . MMuullttiippllee ggiitt rreeppooss uusseeccaasseess • Infrastructure as Code • Projects released together • Projects that embed external libraries • …
  • 14. . ggiitt ssuubbmmoodduulleess • Built-in with git • Embeds external repositories in a subdirectory or your repo • Points these external repositories in a particular commit
  • 15. . ggiitt ssuubbmmoodduulleess • Submodules act like traditional git repositories • Super repo contains a file with the submodules urls • Super repo contains objects that can be updated with commit hashes
  • 16. . IInniittiiaattee ssuuppeerr--rreeppoo . $ git init . Initialized empty Git repository in /home/roidelapluie /super-repo/.git/ $ > README $ git add README $ git commit -m "Initial commit" [master (root-commit) b526be8] Initial commit 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 README .
  • 17. . IInniittiiaattee ssuubbrreeppoo . $ git init . Initialized empty Git repository in /home/roidelapluie /subrepo/.git/ $ > README $ git add README $ git commit -m "Initial commit" [master (root-commit) 41e64b6] Initial commit 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 README .
  • 18. . AAdddd ffiirrssttmmoodduullee iinn ppaarreenntt rreeppoo . $ git submodule add ../subrepo/ subrepo Cloning into 'subrepo'... done. $ git status On branch master Changes to be committed: (use "git reset HEAD <file>..." to unstage) . new file: .gitmodules new file: subrepo
  • 19. . WWhhaatt jjuusstt hhaappppeenneedd?? • git created a .gitmodules file • It cloned the subrepo in a directory • It created a git object that points to the repo • That object contains the git revision
  • 20. . ..ggiittmmoodduulleess ffiillee . $ cat .gitmodules [submodule "subrepo"] . path = subrepo url = ../subrepo/ • Unique file for all the submodules • Only contains the path and the url • In this case, we use relative URL
  • 21. . CCoommmmiittiinngg oouurr cchhaannggee . $ git commit -m "Add subrepo" [master 3251a63] Add subrepo 2 files changed, 4 insertions(+) create mode 100644 .gitmodules create mode 160000 subrepo .
  • 22. . CClloonniinngg tthhaatt ssuuppeerr rreeppoo . $ git clone /home/roidelapluie/super-repo/ . Cloning into '.'... done. $ ls subrepo/ $ git submodule init Submodule 'subrepo' (/home/roidelapluie/subrepo) registered for path 'subrepo' $ git submodule update Cloning into 'subrepo'... done. Submodule path 'subrepo': checked out '41e64b6bc0c97052 1c296b9c5e6a0b9144778962' .
  • 23. . SShhoorrccuutt ##11 . $ git submodule init $ git submodule update . . $ git submodule update --init Submodule 'subrepo' (/home/roidelapluie/subrepo) registered for path 'subrepo' Cloning into 'subrepo'... done. Submodule path 'subrepo': checked out '41e64b6bc0c97052 1c296b9c5e6a0b9144778962' .
  • 24. . SShhoorrccuutt ##22 . $ git clone /home/roidelapluie/super-repo/ . $ git submodule init $ git submodule update . . $ git clone --recurse-submodules /home/roidelapluie/ super-repo/ . Cloning into '.'... done. Submodule 'subrepo' (/home/roidelapluie/subrepo) registered for path 'subrepo' Cloning into 'subrepo'... done. Submodule path 'subrepo': checked out '41e64b6bc0c97052 1c296b9c5e6a0b9144778962' .
  • 25. . WWoorrkkiinngg iinn aa ssuubbmmoodduullee . $ cd subrepo $ > newfile $ git add newfile $ git commit -m "add newfile" [detached HEAD 6ee0e71] add newfile 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 newfile $ git push fatal: You are not currently on a branch. To push the history leading to the current (detached HEAD) state now, use . git push origin HEAD:<name-of-remote-branch>
  • 26. . CChheecckkiinngg oouutt aa bbrraanncchh . $ git checkout master Warning: you are leaving 1 commit behind, not connected to any of your branches: 6ee0e71 add newfile If you want to keep them by creating a new branch, this may be a good time to do so with: git branch new_branch_name 6ee0e71 Switched to branch 'master' Your branch is up-to-date with 'origin/master'. .
  • 27. . MMeerrggiinngg oouurr ccoommmmiitt . $ git merge 6ee0e71 Updating 41e64b6..6ee0e71 Fast-forward newfile | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 newfile .
  • 28. . PPuusshhiinngg oouurr ccoommmmiitt . $ git push Counting objects: 2, done. Delta compression using up to 8 threads. Compressing objects: 100% (2/2), done. Writing objects: 100% (2/2), 247 bytes | 0 bytes/s, done. Total 2 (delta 0), reused 0 (delta 0) To /home/roidelapluie/subrepo . 41e64b6..6ee0e71 master -> master
  • 29. . PPuusshhiinngg oouurr ccoommmmiitt . $ date > newfile $ git commit -am "update newfile" [master 8a56806] update newfile 1 file changed, 1 insertion(+) $ git push Counting objects: 3, done. Delta compression using up to 8 threads. Compressing objects: 100% (2/2), done. Writing objects: 100% (3/3), 310 bytes | 0 bytes/s, done. Total 3 (delta 0), reused 0 (delta 0) To /home/roidelapluie/subrepo . 6ee0e71..8a56806 master -> master
  • 30. . LLeett''ss rreewwiinndd.... • A submodule not attached to a branch ▶ Because submodules are referenced by their commit hash only ▶ It is called the DETACHED HEAD • How to push then? ▶ The easy/safe option is to checkout a branch • You only need to do that once
  • 31. . ggiitt ssuubbmmoodduullee ffoorreeaacchh • git submodule foreach allow you to run a command on each repo ▶ git submodule foreach git checkout master ▶ git submodule foreach ls ▶ git submodule foreach git commit -am "foo"
  • 32. . MMeeaannwwhhiillee,, oonn tthhee ssuuppeerr--pprroojjeecctt…… . $ git status On branch master Changes not staged for commit: (use "git add <file>..." to update what will be committed) (use "git checkout -- <file>..." to discard changes in working directory) . modified: subrepo (new commits) no changes added to commit (use "git add" and/or "git commit -a")
  • 33. . UUppddaattee aa ssuubbrreeppoo . $ git commit -am "update subrepo" [master 731626b] update subrepo 1 file changed, 1 insertion(+), 1 deletion(-) .
  • 34. . LLooggss . $ git log -p --submodule=log subrepo/ commit 731626bc53d8c248647443b4c0523d96d316cd24 Author: Julien Pivotto <roidelapluie@inuits.eu> Date: Sat Oct 25 22:26:56 2014 +0200 . update subrepo Submodule subrepo 41e64b6..01c1b9c: > work on newfile > update newfile > add newfile
  • 35. . CChhaannggee aa ssuubbmmoodduulleess UURRLL • Edit .gitmodules and commit the file • Run git submodule sync • Now the submodule will use the new URL
  • 36. . ggiitt ssuubbmmoodduullee ----rreeccuurrssiivvee • Run commands recursively • You can get multiple levels of submodules • But you add complexity ▶ Each level is 1 more commit you need to write ▶ Playing with remote urls becomes tricky of you work with remotes
  • 37. . SSuubbmmoodduulleess iinntteeggrraattiioonn • Integrated in git, standard • Integrated in CI tools (Jenkins) • Nothing specific needed for pulling • Need to checkout the submodules after pulling
  • 38. . SSuubbmmoodduulleess iinn GGeerrrriitt • Gerrit integrates submodules • It can create commits in "super-repo" if a code change is merged • Not a perfect way of doing if changes in two repo's are depending of each other
  • 39. . SSuubbmmoodduulleess iinn GGeerrrriitt • Gerrit is integrated in CI tools • Gerrit allows fine tuning ACL • Gerrit code reviews with submodules changes don't display changes in the submodules
  • 40. . SSuubbmmoodduulleess pprrooss aanndd ccoonnss Each commit in submodule is not in super-repo It is easy to rollback by accident a submodule Getting logs is not easy You can forget to update super-repo Submodules are not attached to a branch
  • 41. . SSuubbmmoodduulleess pprrooss aanndd ccoonnss + Built-in + Can use relative urls + You can control the version of the submodules + Supported by many tools + Easy rollbacks of submodules + git bissect works (on the super repo)
  • 43. . ggiittssllaavvee • First public release in 2010 • Wrapper around git • gits can be used in place of git • Run each git commands in each subrepos
  • 44. . IInniittiiaattee ggiittss . $ git init . Initialized empty Git repository in /home/roidelapluie/ superrepo/.git/ $ gits prepare [master (root-commit) 594c492] gits creating .gitslave 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 .gitslave .
  • 45. . AAdddd aa ggiitt rreeppoo . $ gits attach /home/roidelapluie/subrepo/ subrepo Cloning into 'subrepo'... done. [master 926321f] gits adding /home/roidelapluie/ subrepo/ subrepo 2 files changed, 2 insertions(+) create mode 100644 .gitignore $ cat .gitslave /home/roidelapluie/subrepo/ subrepo .
  • 46. . CClloonniinngg aa rreeppoo . $ gits clone ../superrepo/ . Cloning into '.'... done. Cloning into 'subrepo'... done. .
  • 47. . WWoorrkkiinngg iinn ssuubbmmoodduulleess . $ cd subrepo $ date newfile $ git add newfile $ gits commit -m Work on newfile On: subrepo: [master 1230de3] Work on newfile . 1 file changed, 1 insertion(+), 1 deletion(-) On: (super-repo): On branch master Your branch is up-to-date with 'origin/master'. nothing to commit, working directory clean
  • 48. . PPuusshhiinngg cchhaannggeess . $ gits push On: subrepo: To /home/roidelapluie/subrepo/ . fbcf73c..1230de3 master - master On: (super-repo): Everything up-to-date
  • 49. . PPuulllliinngg cchhaannggeess . $ gits pull On: (super-repo), subrepo: Already up-to-date. .
  • 50. . ggiitt ssllaavvee wwoorrkkffllooww • Subrepos are always attached to a branch • You can work within them normally • Run almost any git command with gits
  • 51. . PPeerrffoorrmmaannccee • gits --parallel 8: run 8 parallel git commands • No extra commit in the super repository • Close to traditional git workflow
  • 52. . AA bbrraanncchhiinngg aapppprrooaacchh • Use gits branch and gits checkout to switch between branches • All the repositories will switch branches (e.g 1.0, 1.1) • Easy merge with gits merge • Avoid upstream traditional branch names
  • 53. . ggiittss oouuttppuutt • gits will simplify the output of git commands • It will group the repos by output • Easier to see the status, the remotes, etc
  • 54. . PPrrooss aanndd ccoonnss ooff ggiittssllaavvee Not integrated in tools Requires an additional binary Not integrated in git Hard to rollback on every repositories
  • 55. . PPrrooss aanndd ccoonnss ooff ggiittssllaavvee + Close to git workflow + Less error-prone + Use traditional git commands + Every git push arrives in the repo
  • 56. . MMiittiiggeeaattee ggiittssllaavveess'' iissssuueess • Use git hooks to trigger tests on CI ▶ Polling SCM does not scale anyway ▶ Use the Quite period feature • Use CI to add the same tag in each repository ▶ Rollback to a tag, not a commit ▶ Add a tag at each commit
  • 58. . UUssee SSSSHH ssoocckkeettss . $ cat .ssh/config Host githost . controlmaster auto controlpath /tmp/ssh-%r@%h:%p ControlPersist 300 • Use only one SSH connection • Do not disconnect SSH
  • 59. . FFiinndd tthhee ttaagg ooff aa ccoommmmiitt . $ git name-rev --name-only 106cb38dd0bc5ea2d2d0adef0b40 06bd61884e42 remotes/origin/8.5.2~1 .
  • 60. . ggiitt aauuttooccoorrrreecctt . $ git config help.autocorrect 10 $ git pusk WARNING: You called a Git command named 'pusk', which does not Continuing under the assumption that you meant 'push' in 1.0 seconds automatically... .
  • 61. . UUssee ggiitt hhooookkss • Multiple repositories = a lot of pull • Jenkins pulling X repos X times every 5 minutes is a bad idea • Git hooks to the resue • Reduce load on Jenkins and the git server • Reduce the time before Jenkins launches builds
  • 62. . GGPPGG--SSiiggnn yyoouurr ccoommmmiittss • git commit -S • Sign PR, merge commits • Do not sign every commit (then it becomes useless)
  • 63. . KKeeeeppiinnggmmuullttiippllee rreemmootteess iinn ssyynncc • git remote set-url --add • Pull push will ose both urls
  • 64. . HHoommeewwoorrkk • Git subtree (also built-in) • Repo (from Android) • gr • …
  • 65. . CCoonncclluussiioonnss • Git is an awesome, extandable tool • There are several ways to manage multiple git repositories • Working with multiple repos is easy • You have to learn tools anyway • Experiment them and pick one :-)
  • 66. . TThhaannkk yyoouu Any question?
  • 67. . CCoonnttaacctt Julien Pivotto julien@inuits.eu @roidelapluie INUITS bvba Belgium +32 473 441 636 https://inuits.eu