SlideShare a Scribd company logo
Git flow & Git
Init a project with existing files
git flow init
Creates two branches:
master (production release)
develop (next release)
Supported branches prefixes:
feature
release
hotfix
After finishing "my-hotfix", master and develop have the
commits made in the hotfix branch
Hotfixes workflow
Command master my-hotfix develop
git flow hotfix start my-hotfix
working in hotfix
git commit -am "msg"
git flow hotfix finish my-hotfix
git flow hotfix start my-hotfix
is equivalent to the next git commands
git checkout master
git branch hotfix/my-hotfix
git checkout hotfix/my-hotfix
or
git checkout -b hotfix/my-hotfix master
Starting a hotfix
git flow hotfix finish my-hotfix
is equivalent to the next git commands
git checkout master
git merge --no-ff hotfix/my-hotfix
git checkout develop
git merge --no-ff hotfix/my-hotfix
git branch -d hotfix/my-hotfix
don't forget to push master and develop into origin
git push origin [master|develop]
Finishing a hotfix
After finishing "my-feature", only develop has the commits
made in the feature branch
Features workflow
Command master my-feature develop
git flow feature start my-feature
working in feature
git commit -am "msg"
git flow feature finish my-feature
git flow feature start my-feature
is equivalent to the next git commands
git checkout develop
git branch feature/my-feature
git checkout feature/my-feature
or
git checkout -b feature/my-feature develop
Starting a feature
git flow feature finish my-feature
is equivalent to the next git commands
git checkout develop
git merge --no-ff feature/my-feature
git branch -d feature/my-feature
don't forget to push develop into origin
git push origin develop
Finishing a feature
After finishing "v2.0", master and develop have the commits
made in the release branch
Releases workflow
Command master v2.0 develop
git flow release start v2.0
working in release
git commit -am "msg"
git flow feature finish v2.0
git flow release start my-release
is equivalent to the next git commands
git checkout develop
git branch release/my-release
git checkout release/my-release
or
git checkout -b release/my-release develop
Starting a release
git flow release finish my-release
is equivalent to the next git commands
git checkout master
git merge --no-ff release/my-release
git tag -a my-release
git checkout develop
git merge --no-ff release/my-release
git branch -d release/my-release
don't forget to push master and develop into origin
git push origin [master|develop]
Finishing a release
Hotfixes
git checkout master
git pull
git checkout hotfix-branch
git merge master
Features
git checkout develop
git pull
git checkout feature-branch
git merge develop
What if my branch gets obsolete?
git flow [hotfix|feature|release] publish my-branch
you can checkout remote branches like this
git checkout -b my-branch origin/my-branch
don't forget to remove them when they are not needed
anymore
git push origin :my-branch
Publishing remote branches
Suitable to support old versions of the software but in a
very EXPERIMENTAL status and NOT RECOMENDABLE
for production environments
git flow support start v1.1.1 v1.0
Support branches
Useful git
commands
Log of the last 2 commits
git log -2
Differences in the last 2 commits
git log -2 -p
Differences between commits
git diff 77cf297..eb0df61
gif diff --name-only 77cf297..eb0df61f
git diff HEAD..HEAD^1 filename
Showing the last commits
Useful when we need to checkout another branch and we
don't still want to commit anything
git stash
git stash list
git stash pop
git stash apply stash@{0}
git stash show stash@{1}
git stash drop stash@{0}
Saving work without committing
If the file hasn't been added to the index
git checkout one.txt
If the file has already been added to the index
git reset HEAD one.txt
If we want to undo a commit but keeping the modifications
git reset --soft sha1_commit
If we want to undo a commit completely
git reset --hard sha1_commit
Throwing changes away
Fixing mistakes
with git
Committing too early
git commit -m "my message"
I forgot to add the file one.txt and I don't want to do another
commit
git add one.txt
git commit --amend
Committing too early again
git add two.txt three.txt
git commit -m "my message"
I don't want the file three.txt in this commit
git reset HEAD^1 three.txt
git commit --amend
Fixing mistakes in previous commits
An error in the file four.txt was introduced in a previous commit
git checkout <SHA1_commit>
vim four.txt
git add four.txt
git commit --amend
git rebase --onto HEAD <SHA1_commit> <branch>
Recovering local deleted branch
git branch -D my-feature
Looking for the last commit in the deleted branch and
getting its SHA1 with git reflog
git branch my-feature <sha1_last_commit>
Links
● http://git-scm.com/documentation
● http://nvie.com/posts/a-successful-git-branching-model/

More Related Content

What's hot

Learning git
Learning gitLearning git
Learning git
Sid Anand
 
Git Series. Episode 3. Git Flow and Github-Flow
Git Series. Episode 3. Git Flow and Github-FlowGit Series. Episode 3. Git Flow and Github-Flow
Git Series. Episode 3. Git Flow and Github-Flow
Mikhail Melnik
 
A Git Workflow Model or Branching Strategy
A Git Workflow Model or Branching StrategyA Git Workflow Model or Branching Strategy
A Git Workflow Model or Branching Strategy
Vivek Parihar
 
Git - Basic Crash Course
Git - Basic Crash CourseGit - Basic Crash Course
Git - Basic Crash Course
Nilay Binjola
 
Git branching strategies
Git branching strategiesGit branching strategies
Git branching strategies
jstack
 
Git workflows presentation
Git workflows presentationGit workflows presentation
Git workflows presentation
Mack Hardy
 
Git slides
Git slidesGit slides
Git slides
Nanyak S
 
Git
GitGit
Git Terminologies
Git TerminologiesGit Terminologies
Git Terminologies
Yash
 
Git n git hub
Git n git hubGit n git hub
Git n git hub
Jiwon Baek
 
git and github
git and githubgit and github
git and github
Darren Oakley
 
Git
GitGit
Git and github 101
Git and github 101Git and github 101
Git and github 101
Senthilkumar Gopal
 
Git and Github slides.pdf
Git and Github slides.pdfGit and Github slides.pdf
Git and Github slides.pdf
Tilton2
 
Git
GitGit
Git & GitHub WorkShop
Git & GitHub WorkShopGit & GitHub WorkShop
Git & GitHub WorkShop
SheilaJimenezMorejon
 
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 One Day Training Notes
Git One Day Training NotesGit One Day Training Notes
Git One Day Training Notes
glen_a_smith
 
Github - Git Training Slides: Foundations
Github - Git Training Slides: FoundationsGithub - Git Training Slides: Foundations
Github - Git Training Slides: Foundations
Lee Hanxue
 
Git-flow workflow and pull-requests
Git-flow workflow and pull-requestsGit-flow workflow and pull-requests
Git-flow workflow and pull-requests
Bartosz Kosarzycki
 

What's hot (20)

Learning git
Learning gitLearning git
Learning git
 
Git Series. Episode 3. Git Flow and Github-Flow
Git Series. Episode 3. Git Flow and Github-FlowGit Series. Episode 3. Git Flow and Github-Flow
Git Series. Episode 3. Git Flow and Github-Flow
 
A Git Workflow Model or Branching Strategy
A Git Workflow Model or Branching StrategyA Git Workflow Model or Branching Strategy
A Git Workflow Model or Branching Strategy
 
Git - Basic Crash Course
Git - Basic Crash CourseGit - Basic Crash Course
Git - Basic Crash Course
 
Git branching strategies
Git branching strategiesGit branching strategies
Git branching strategies
 
Git workflows presentation
Git workflows presentationGit workflows presentation
Git workflows presentation
 
Git slides
Git slidesGit slides
Git slides
 
Git
GitGit
Git
 
Git Terminologies
Git TerminologiesGit Terminologies
Git Terminologies
 
Git n git hub
Git n git hubGit n git hub
Git n git hub
 
git and github
git and githubgit and github
git and github
 
Git
GitGit
Git
 
Git and github 101
Git and github 101Git and github 101
Git and github 101
 
Git and Github slides.pdf
Git and Github slides.pdfGit and Github slides.pdf
Git and Github slides.pdf
 
Git
GitGit
Git
 
Git & GitHub WorkShop
Git & GitHub WorkShopGit & GitHub WorkShop
Git & GitHub WorkShop
 
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 One Day Training Notes
Git One Day Training NotesGit One Day Training Notes
Git One Day Training Notes
 
Github - Git Training Slides: Foundations
Github - Git Training Slides: FoundationsGithub - Git Training Slides: Foundations
Github - Git Training Slides: Foundations
 
Git-flow workflow and pull-requests
Git-flow workflow and pull-requestsGit-flow workflow and pull-requests
Git-flow workflow and pull-requests
 

Viewers also liked

Web 2.0 - From a Social to a Service Web
Web 2.0 - From a Social to a Service WebWeb 2.0 - From a Social to a Service Web
Web 2.0 - From a Social to a Service Web
Jury Konga
 
Micro Web Service - Slim and JWT
Micro Web Service - Slim and JWTMicro Web Service - Slim and JWT
Micro Web Service - Slim and JWT
Tuyen Vuong
 
Creating REST Applications with the Slim Micro-Framework by Vikram Vaswani
Creating REST Applications with the Slim Micro-Framework by Vikram VaswaniCreating REST Applications with the Slim Micro-Framework by Vikram Vaswani
Creating REST Applications with the Slim Micro-Framework by Vikram Vaswani
vvaswani
 
Por su seguridad
Por su seguridadPor su seguridad
Por su seguridad
Jose Manuel Ortega Candel
 
Groovy&Grails: desarrollo rápido de aplicaciones
Groovy&Grails: desarrollo rápido de aplicacionesGroovy&Grails: desarrollo rápido de aplicaciones
Groovy&Grails: desarrollo rápido de aplicaciones
Fran García
 
Privacidad internet
Privacidad internetPrivacidad internet
Privacidad internet
Jose Manuel Ortega Candel
 
Certificaciones Tecnológicas: La acreditación del experto
Certificaciones Tecnológicas: La acreditación del expertoCertificaciones Tecnológicas: La acreditación del experto
Certificaciones Tecnológicas: La acreditación del experto
Jose Manuel Ortega Candel
 
Inteligencia Colectiva
Inteligencia ColectivaInteligencia Colectiva
Inteligencia Colectiva
Domingo Gallardo
 
Herramientas gestion proyectos
Herramientas gestion proyectosHerramientas gestion proyectos
Herramientas gestion proyectos
Jose Manuel Ortega Candel
 
Seguridad en dispositivos móviles
Seguridad en dispositivos móvilesSeguridad en dispositivos móviles
Seguridad en dispositivos móviles
Jose Manuel Ortega Candel
 
Certificaciones tecnológicas
Certificaciones tecnológicasCertificaciones tecnológicas
Certificaciones tecnológicas
Jose Manuel Ortega Candel
 
Kanban
KanbanKanban
Groovy&Grails: desarrollo rápido de aplicaciones
Groovy&Grails: desarrollo rápido de aplicacionesGroovy&Grails: desarrollo rápido de aplicaciones
Groovy&Grails: desarrollo rápido de aplicaciones
Fran García
 
Manual de uso de la web 2.0
Manual de uso de la web 2.0Manual de uso de la web 2.0
Manual de uso de la web 2.0
Domingo Gallardo
 
Continuous Delivery
Continuous DeliveryContinuous Delivery
Continuous Delivery
Domingo Gallardo
 
Working with the AOSP - Linaro Connect Asia 2013
Working with the AOSP - Linaro Connect Asia 2013Working with the AOSP - Linaro Connect Asia 2013
Working with the AOSP - Linaro Connect Asia 2013
Opersys inc.
 
Framework de test spock
Framework de test spock Framework de test spock
Framework de test spock
Fran García
 
Json web token api authorization
Json web token api authorizationJson web token api authorization
Json web token api authorization
Giulio De Donato
 
Metodologías agiles de desarrollo de software
Metodologías agiles de desarrollo de softwareMetodologías agiles de desarrollo de software
Metodologías agiles de desarrollo de software
Domingo Gallardo
 
Testing NodeJS Security
Testing NodeJS SecurityTesting NodeJS Security
Testing NodeJS Security
Jose Manuel Ortega Candel
 

Viewers also liked (20)

Web 2.0 - From a Social to a Service Web
Web 2.0 - From a Social to a Service WebWeb 2.0 - From a Social to a Service Web
Web 2.0 - From a Social to a Service Web
 
Micro Web Service - Slim and JWT
Micro Web Service - Slim and JWTMicro Web Service - Slim and JWT
Micro Web Service - Slim and JWT
 
Creating REST Applications with the Slim Micro-Framework by Vikram Vaswani
Creating REST Applications with the Slim Micro-Framework by Vikram VaswaniCreating REST Applications with the Slim Micro-Framework by Vikram Vaswani
Creating REST Applications with the Slim Micro-Framework by Vikram Vaswani
 
Por su seguridad
Por su seguridadPor su seguridad
Por su seguridad
 
Groovy&Grails: desarrollo rápido de aplicaciones
Groovy&Grails: desarrollo rápido de aplicacionesGroovy&Grails: desarrollo rápido de aplicaciones
Groovy&Grails: desarrollo rápido de aplicaciones
 
Privacidad internet
Privacidad internetPrivacidad internet
Privacidad internet
 
Certificaciones Tecnológicas: La acreditación del experto
Certificaciones Tecnológicas: La acreditación del expertoCertificaciones Tecnológicas: La acreditación del experto
Certificaciones Tecnológicas: La acreditación del experto
 
Inteligencia Colectiva
Inteligencia ColectivaInteligencia Colectiva
Inteligencia Colectiva
 
Herramientas gestion proyectos
Herramientas gestion proyectosHerramientas gestion proyectos
Herramientas gestion proyectos
 
Seguridad en dispositivos móviles
Seguridad en dispositivos móvilesSeguridad en dispositivos móviles
Seguridad en dispositivos móviles
 
Certificaciones tecnológicas
Certificaciones tecnológicasCertificaciones tecnológicas
Certificaciones tecnológicas
 
Kanban
KanbanKanban
Kanban
 
Groovy&Grails: desarrollo rápido de aplicaciones
Groovy&Grails: desarrollo rápido de aplicacionesGroovy&Grails: desarrollo rápido de aplicaciones
Groovy&Grails: desarrollo rápido de aplicaciones
 
Manual de uso de la web 2.0
Manual de uso de la web 2.0Manual de uso de la web 2.0
Manual de uso de la web 2.0
 
Continuous Delivery
Continuous DeliveryContinuous Delivery
Continuous Delivery
 
Working with the AOSP - Linaro Connect Asia 2013
Working with the AOSP - Linaro Connect Asia 2013Working with the AOSP - Linaro Connect Asia 2013
Working with the AOSP - Linaro Connect Asia 2013
 
Framework de test spock
Framework de test spock Framework de test spock
Framework de test spock
 
Json web token api authorization
Json web token api authorizationJson web token api authorization
Json web token api authorization
 
Metodologías agiles de desarrollo de software
Metodologías agiles de desarrollo de softwareMetodologías agiles de desarrollo de software
Metodologías agiles de desarrollo de software
 
Testing NodeJS Security
Testing NodeJS SecurityTesting NodeJS Security
Testing NodeJS Security
 

Similar to Git and git flow

Checkitmobile - using Git for development
Checkitmobile - using Git for developmentCheckitmobile - using Git for development
Checkitmobile - using Git for development
Gerrit Wanderer
 
Git development workflow
Git development workflowGit development workflow
Git development workflow
Sankar Suda
 
Mastering git - Workflow
Mastering git - WorkflowMastering git - Workflow
Mastering git - Workflow
Tahsin Abrar
 
Git commands
Git commandsGit commands
Git commands
Viyaan Jhiingade
 
Managing releases effectively through git
Managing releases effectively through gitManaging releases effectively through git
Managing releases effectively through git
Mohd Farid
 
GIT in a nutshell
GIT in a nutshellGIT in a nutshell
GIT in a nutshell
alignan
 
Git - Version Control System
Git - Version Control SystemGit - Version Control System
Git - Version Control System
Namig Hajiyev
 
Pro git - grasping it conceptually
Pro git - grasping it conceptuallyPro git - grasping it conceptually
Pro git - grasping it conceptually
seungzzang Kim
 
Gitflow - Una metología para manejo de Branches
Gitflow - Una metología para manejo de BranchesGitflow - Una metología para manejo de Branches
Gitflow - Una metología para manejo de Branches
Javier Alvarez
 
GIT Basics
GIT BasicsGIT Basics
GIT Basics
Tagged Social
 
How to use git without rage
How to use git without rageHow to use git without rage
How to use git without rage
Javier Lafora Rey
 
Gitflow - Branching and Merging Flow for Git
Gitflow - Branching and Merging Flow for GitGitflow - Branching and Merging Flow for Git
Gitflow - Branching and Merging Flow for Git
Maulik Shah
 
Gitflow - Branching and Merging Flow for Git
Gitflow - Branching and Merging Flow for GitGitflow - Branching and Merging Flow for Git
Gitflow - Branching and Merging Flow for Git
Maulik Shah
 
Git in 10 minutes
Git in 10 minutesGit in 10 minutes
Git in 10 minutes
Safique Ahmed Faruque
 
Checkitmobile advanced git
Checkitmobile advanced gitCheckitmobile advanced git
Checkitmobile advanced git
Gerrit Wanderer
 
Advanced Git Tutorial
Advanced Git TutorialAdvanced Git Tutorial
Advanced Git Tutorial
Sage Sharp
 
Git Tricks — git utilities that make life git easier
Git Tricks — git utilities that make life git easierGit Tricks — git utilities that make life git easier
Git Tricks — git utilities that make life git easier
Christoph Matthies
 
Gitt and Git-flow
Gitt and Git-flowGitt and Git-flow
Gitt and Git-flow
Md. Masud
 
Git github
Git githubGit github
Git github
Anurag Deb
 
Gitflow
GitflowGitflow
Gitflow
Phuoc Bui
 

Similar to Git and git flow (20)

Checkitmobile - using Git for development
Checkitmobile - using Git for developmentCheckitmobile - using Git for development
Checkitmobile - using Git for development
 
Git development workflow
Git development workflowGit development workflow
Git development workflow
 
Mastering git - Workflow
Mastering git - WorkflowMastering git - Workflow
Mastering git - Workflow
 
Git commands
Git commandsGit commands
Git commands
 
Managing releases effectively through git
Managing releases effectively through gitManaging releases effectively through git
Managing releases effectively through git
 
GIT in a nutshell
GIT in a nutshellGIT in a nutshell
GIT in a nutshell
 
Git - Version Control System
Git - Version Control SystemGit - Version Control System
Git - Version Control System
 
Pro git - grasping it conceptually
Pro git - grasping it conceptuallyPro git - grasping it conceptually
Pro git - grasping it conceptually
 
Gitflow - Una metología para manejo de Branches
Gitflow - Una metología para manejo de BranchesGitflow - Una metología para manejo de Branches
Gitflow - Una metología para manejo de Branches
 
GIT Basics
GIT BasicsGIT Basics
GIT Basics
 
How to use git without rage
How to use git without rageHow to use git without rage
How to use git without rage
 
Gitflow - Branching and Merging Flow for Git
Gitflow - Branching and Merging Flow for GitGitflow - Branching and Merging Flow for Git
Gitflow - Branching and Merging Flow for Git
 
Gitflow - Branching and Merging Flow for Git
Gitflow - Branching and Merging Flow for GitGitflow - Branching and Merging Flow for Git
Gitflow - Branching and Merging Flow for Git
 
Git in 10 minutes
Git in 10 minutesGit in 10 minutes
Git in 10 minutes
 
Checkitmobile advanced git
Checkitmobile advanced gitCheckitmobile advanced git
Checkitmobile advanced git
 
Advanced Git Tutorial
Advanced Git TutorialAdvanced Git Tutorial
Advanced Git Tutorial
 
Git Tricks — git utilities that make life git easier
Git Tricks — git utilities that make life git easierGit Tricks — git utilities that make life git easier
Git Tricks — git utilities that make life git easier
 
Gitt and Git-flow
Gitt and Git-flowGitt and Git-flow
Gitt and Git-flow
 
Git github
Git githubGit github
Git github
 
Gitflow
GitflowGitflow
Gitflow
 

Recently uploaded

MAKE MONEY ONLINE Unlock Your Income Potential Today.pptx
MAKE MONEY ONLINE Unlock Your Income Potential Today.pptxMAKE MONEY ONLINE Unlock Your Income Potential Today.pptx
MAKE MONEY ONLINE Unlock Your Income Potential Today.pptx
janagijoythi
 
Computer HARDWARE presenattion by CWD students class 10
Computer HARDWARE presenattion by CWD students class 10Computer HARDWARE presenattion by CWD students class 10
Computer HARDWARE presenattion by CWD students class 10
ankush9927
 
Integrating Kafka with MuleSoft 4 and usecase
Integrating Kafka with MuleSoft 4 and usecaseIntegrating Kafka with MuleSoft 4 and usecase
Integrating Kafka with MuleSoft 4 and usecase
shyamraj55
 
Accelerating Migrations = Recommendations
Accelerating Migrations = RecommendationsAccelerating Migrations = Recommendations
Accelerating Migrations = Recommendations
isBullShit
 
Mastering OnlyFans Clone App Development: Key Strategies for Success
Mastering OnlyFans Clone App Development: Key Strategies for SuccessMastering OnlyFans Clone App Development: Key Strategies for Success
Mastering OnlyFans Clone App Development: Key Strategies for Success
David Wilson
 
leewayhertz.com-Generative AI tech stack Frameworks infrastructure models and...
leewayhertz.com-Generative AI tech stack Frameworks infrastructure models and...leewayhertz.com-Generative AI tech stack Frameworks infrastructure models and...
leewayhertz.com-Generative AI tech stack Frameworks infrastructure models and...
alexjohnson7307
 
Zaitechno Handheld Raman Spectrometer.pdf
Zaitechno Handheld Raman Spectrometer.pdfZaitechno Handheld Raman Spectrometer.pdf
Zaitechno Handheld Raman Spectrometer.pdf
AmandaCheung15
 
COVID-19 and the Level of Cloud Computing Adoption: A Study of Sri Lankan Inf...
COVID-19 and the Level of Cloud Computing Adoption: A Study of Sri Lankan Inf...COVID-19 and the Level of Cloud Computing Adoption: A Study of Sri Lankan Inf...
COVID-19 and the Level of Cloud Computing Adoption: A Study of Sri Lankan Inf...
AimanAthambawa1
 
Types of Weaving loom machine & it's technology
Types of Weaving loom machine & it's technologyTypes of Weaving loom machine & it's technology
Types of Weaving loom machine & it's technology
ldtexsolbl
 
LeadMagnet IQ Review: Unlock the Secret to Effortless Traffic and Leads.pdf
LeadMagnet IQ Review:  Unlock the Secret to Effortless Traffic and Leads.pdfLeadMagnet IQ Review:  Unlock the Secret to Effortless Traffic and Leads.pdf
LeadMagnet IQ Review: Unlock the Secret to Effortless Traffic and Leads.pdf
SelfMade bd
 
Semantic-Aware Code Model: Elevating the Future of Software Development
Semantic-Aware Code Model: Elevating the Future of Software DevelopmentSemantic-Aware Code Model: Elevating the Future of Software Development
Semantic-Aware Code Model: Elevating the Future of Software Development
Baishakhi Ray
 
Perth MuleSoft Meetup July 2024
Perth MuleSoft Meetup July 2024Perth MuleSoft Meetup July 2024
Perth MuleSoft Meetup July 2024
Michael Price
 
Girls call Kolkata 👀 XXXXXXXXXXX 👀 Rs.9.5 K Cash Payment With Room Delivery
Girls call Kolkata 👀 XXXXXXXXXXX 👀 Rs.9.5 K Cash Payment With Room Delivery Girls call Kolkata 👀 XXXXXXXXXXX 👀 Rs.9.5 K Cash Payment With Room Delivery
Girls call Kolkata 👀 XXXXXXXXXXX 👀 Rs.9.5 K Cash Payment With Room Delivery
sunilverma7884
 
Generative AI Reasoning Tech Talk - July 2024
Generative AI Reasoning Tech Talk - July 2024Generative AI Reasoning Tech Talk - July 2024
Generative AI Reasoning Tech Talk - July 2024
siddu769252
 
Retrieval Augmented Generation Evaluation with Ragas
Retrieval Augmented Generation Evaluation with RagasRetrieval Augmented Generation Evaluation with Ragas
Retrieval Augmented Generation Evaluation with Ragas
Zilliz
 
EuroPython 2024 - Streamlining Testing in a Large Python Codebase
EuroPython 2024 - Streamlining Testing in a Large Python CodebaseEuroPython 2024 - Streamlining Testing in a Large Python Codebase
EuroPython 2024 - Streamlining Testing in a Large Python Codebase
Jimmy Lai
 
The History of Embeddings & Multimodal Embeddings
The History of Embeddings & Multimodal EmbeddingsThe History of Embeddings & Multimodal Embeddings
The History of Embeddings & Multimodal Embeddings
Zilliz
 
Premium Girls Call Mumbai 9920725232 Unlimited Short Providing Girls Service ...
Premium Girls Call Mumbai 9920725232 Unlimited Short Providing Girls Service ...Premium Girls Call Mumbai 9920725232 Unlimited Short Providing Girls Service ...
Premium Girls Call Mumbai 9920725232 Unlimited Short Providing Girls Service ...
shanihomely
 
Uncharted Together- Navigating AI's New Frontiers in Libraries
Uncharted Together- Navigating AI's New Frontiers in LibrariesUncharted Together- Navigating AI's New Frontiers in Libraries
Uncharted Together- Navigating AI's New Frontiers in Libraries
Brian Pichman
 
Vulnerability Management: A Comprehensive Overview
Vulnerability Management: A Comprehensive OverviewVulnerability Management: A Comprehensive Overview
Vulnerability Management: A Comprehensive Overview
Steven Carlson
 

Recently uploaded (20)

MAKE MONEY ONLINE Unlock Your Income Potential Today.pptx
MAKE MONEY ONLINE Unlock Your Income Potential Today.pptxMAKE MONEY ONLINE Unlock Your Income Potential Today.pptx
MAKE MONEY ONLINE Unlock Your Income Potential Today.pptx
 
Computer HARDWARE presenattion by CWD students class 10
Computer HARDWARE presenattion by CWD students class 10Computer HARDWARE presenattion by CWD students class 10
Computer HARDWARE presenattion by CWD students class 10
 
Integrating Kafka with MuleSoft 4 and usecase
Integrating Kafka with MuleSoft 4 and usecaseIntegrating Kafka with MuleSoft 4 and usecase
Integrating Kafka with MuleSoft 4 and usecase
 
Accelerating Migrations = Recommendations
Accelerating Migrations = RecommendationsAccelerating Migrations = Recommendations
Accelerating Migrations = Recommendations
 
Mastering OnlyFans Clone App Development: Key Strategies for Success
Mastering OnlyFans Clone App Development: Key Strategies for SuccessMastering OnlyFans Clone App Development: Key Strategies for Success
Mastering OnlyFans Clone App Development: Key Strategies for Success
 
leewayhertz.com-Generative AI tech stack Frameworks infrastructure models and...
leewayhertz.com-Generative AI tech stack Frameworks infrastructure models and...leewayhertz.com-Generative AI tech stack Frameworks infrastructure models and...
leewayhertz.com-Generative AI tech stack Frameworks infrastructure models and...
 
Zaitechno Handheld Raman Spectrometer.pdf
Zaitechno Handheld Raman Spectrometer.pdfZaitechno Handheld Raman Spectrometer.pdf
Zaitechno Handheld Raman Spectrometer.pdf
 
COVID-19 and the Level of Cloud Computing Adoption: A Study of Sri Lankan Inf...
COVID-19 and the Level of Cloud Computing Adoption: A Study of Sri Lankan Inf...COVID-19 and the Level of Cloud Computing Adoption: A Study of Sri Lankan Inf...
COVID-19 and the Level of Cloud Computing Adoption: A Study of Sri Lankan Inf...
 
Types of Weaving loom machine & it's technology
Types of Weaving loom machine & it's technologyTypes of Weaving loom machine & it's technology
Types of Weaving loom machine & it's technology
 
LeadMagnet IQ Review: Unlock the Secret to Effortless Traffic and Leads.pdf
LeadMagnet IQ Review:  Unlock the Secret to Effortless Traffic and Leads.pdfLeadMagnet IQ Review:  Unlock the Secret to Effortless Traffic and Leads.pdf
LeadMagnet IQ Review: Unlock the Secret to Effortless Traffic and Leads.pdf
 
Semantic-Aware Code Model: Elevating the Future of Software Development
Semantic-Aware Code Model: Elevating the Future of Software DevelopmentSemantic-Aware Code Model: Elevating the Future of Software Development
Semantic-Aware Code Model: Elevating the Future of Software Development
 
Perth MuleSoft Meetup July 2024
Perth MuleSoft Meetup July 2024Perth MuleSoft Meetup July 2024
Perth MuleSoft Meetup July 2024
 
Girls call Kolkata 👀 XXXXXXXXXXX 👀 Rs.9.5 K Cash Payment With Room Delivery
Girls call Kolkata 👀 XXXXXXXXXXX 👀 Rs.9.5 K Cash Payment With Room Delivery Girls call Kolkata 👀 XXXXXXXXXXX 👀 Rs.9.5 K Cash Payment With Room Delivery
Girls call Kolkata 👀 XXXXXXXXXXX 👀 Rs.9.5 K Cash Payment With Room Delivery
 
Generative AI Reasoning Tech Talk - July 2024
Generative AI Reasoning Tech Talk - July 2024Generative AI Reasoning Tech Talk - July 2024
Generative AI Reasoning Tech Talk - July 2024
 
Retrieval Augmented Generation Evaluation with Ragas
Retrieval Augmented Generation Evaluation with RagasRetrieval Augmented Generation Evaluation with Ragas
Retrieval Augmented Generation Evaluation with Ragas
 
EuroPython 2024 - Streamlining Testing in a Large Python Codebase
EuroPython 2024 - Streamlining Testing in a Large Python CodebaseEuroPython 2024 - Streamlining Testing in a Large Python Codebase
EuroPython 2024 - Streamlining Testing in a Large Python Codebase
 
The History of Embeddings & Multimodal Embeddings
The History of Embeddings & Multimodal EmbeddingsThe History of Embeddings & Multimodal Embeddings
The History of Embeddings & Multimodal Embeddings
 
Premium Girls Call Mumbai 9920725232 Unlimited Short Providing Girls Service ...
Premium Girls Call Mumbai 9920725232 Unlimited Short Providing Girls Service ...Premium Girls Call Mumbai 9920725232 Unlimited Short Providing Girls Service ...
Premium Girls Call Mumbai 9920725232 Unlimited Short Providing Girls Service ...
 
Uncharted Together- Navigating AI's New Frontiers in Libraries
Uncharted Together- Navigating AI's New Frontiers in LibrariesUncharted Together- Navigating AI's New Frontiers in Libraries
Uncharted Together- Navigating AI's New Frontiers in Libraries
 
Vulnerability Management: A Comprehensive Overview
Vulnerability Management: A Comprehensive OverviewVulnerability Management: A Comprehensive Overview
Vulnerability Management: A Comprehensive Overview
 

Git and git flow

  • 2. Init a project with existing files git flow init Creates two branches: master (production release) develop (next release) Supported branches prefixes: feature release hotfix
  • 3. After finishing "my-hotfix", master and develop have the commits made in the hotfix branch Hotfixes workflow Command master my-hotfix develop git flow hotfix start my-hotfix working in hotfix git commit -am "msg" git flow hotfix finish my-hotfix
  • 4. git flow hotfix start my-hotfix is equivalent to the next git commands git checkout master git branch hotfix/my-hotfix git checkout hotfix/my-hotfix or git checkout -b hotfix/my-hotfix master Starting a hotfix
  • 5. git flow hotfix finish my-hotfix is equivalent to the next git commands git checkout master git merge --no-ff hotfix/my-hotfix git checkout develop git merge --no-ff hotfix/my-hotfix git branch -d hotfix/my-hotfix don't forget to push master and develop into origin git push origin [master|develop] Finishing a hotfix
  • 6. After finishing "my-feature", only develop has the commits made in the feature branch Features workflow Command master my-feature develop git flow feature start my-feature working in feature git commit -am "msg" git flow feature finish my-feature
  • 7. git flow feature start my-feature is equivalent to the next git commands git checkout develop git branch feature/my-feature git checkout feature/my-feature or git checkout -b feature/my-feature develop Starting a feature
  • 8. git flow feature finish my-feature is equivalent to the next git commands git checkout develop git merge --no-ff feature/my-feature git branch -d feature/my-feature don't forget to push develop into origin git push origin develop Finishing a feature
  • 9. After finishing "v2.0", master and develop have the commits made in the release branch Releases workflow Command master v2.0 develop git flow release start v2.0 working in release git commit -am "msg" git flow feature finish v2.0
  • 10. git flow release start my-release is equivalent to the next git commands git checkout develop git branch release/my-release git checkout release/my-release or git checkout -b release/my-release develop Starting a release
  • 11. git flow release finish my-release is equivalent to the next git commands git checkout master git merge --no-ff release/my-release git tag -a my-release git checkout develop git merge --no-ff release/my-release git branch -d release/my-release don't forget to push master and develop into origin git push origin [master|develop] Finishing a release
  • 12. Hotfixes git checkout master git pull git checkout hotfix-branch git merge master Features git checkout develop git pull git checkout feature-branch git merge develop What if my branch gets obsolete?
  • 13. git flow [hotfix|feature|release] publish my-branch you can checkout remote branches like this git checkout -b my-branch origin/my-branch don't forget to remove them when they are not needed anymore git push origin :my-branch Publishing remote branches
  • 14. Suitable to support old versions of the software but in a very EXPERIMENTAL status and NOT RECOMENDABLE for production environments git flow support start v1.1.1 v1.0 Support branches
  • 16. Log of the last 2 commits git log -2 Differences in the last 2 commits git log -2 -p Differences between commits git diff 77cf297..eb0df61 gif diff --name-only 77cf297..eb0df61f git diff HEAD..HEAD^1 filename Showing the last commits
  • 17. Useful when we need to checkout another branch and we don't still want to commit anything git stash git stash list git stash pop git stash apply stash@{0} git stash show stash@{1} git stash drop stash@{0} Saving work without committing
  • 18. If the file hasn't been added to the index git checkout one.txt If the file has already been added to the index git reset HEAD one.txt If we want to undo a commit but keeping the modifications git reset --soft sha1_commit If we want to undo a commit completely git reset --hard sha1_commit Throwing changes away
  • 20. Committing too early git commit -m "my message" I forgot to add the file one.txt and I don't want to do another commit git add one.txt git commit --amend
  • 21. Committing too early again git add two.txt three.txt git commit -m "my message" I don't want the file three.txt in this commit git reset HEAD^1 three.txt git commit --amend
  • 22. Fixing mistakes in previous commits An error in the file four.txt was introduced in a previous commit git checkout <SHA1_commit> vim four.txt git add four.txt git commit --amend git rebase --onto HEAD <SHA1_commit> <branch>
  • 23. Recovering local deleted branch git branch -D my-feature Looking for the last commit in the deleted branch and getting its SHA1 with git reflog git branch my-feature <sha1_last_commit>