SlideShare a Scribd company logo
Git presentation
Agenda
●

Git introduction

●

Why Git?

●

Git VS Subversion

●

Basic Commands

●

Branching & Merging

●

Typical Workflow
Git introduction
●

Distributed Version Control System

●

Speed & Efficiency

●

Decentralized
Why Git?
●

Distributed

●

Non-linear

●

Scale

Recommended for you

Basic Git Intro
Basic Git IntroBasic Git Intro
Basic Git Intro

A Basic Git intro presentation for SVN long timers doing their first steps in Git. This presentation is meant to clear up most of the basic concepts which cause confusion with developers using Git as if it was an SVN.

introsimplebasic
Introduction to git
Introduction to gitIntroduction to git
Introduction to git

This document provides a brief introduction to Git, a distributed version control system. It describes what Git is and some of its key features, such as tracking changes to files over time, supporting distributed development, efficient object storage, easy branching and merging, and universal public identifiers. The document also discusses some of Git's internal mechanisms, such as SHA-1 hashes to uniquely identify objects, the index cache, and how commits and branches work.

git
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

Find out why more and more developers are switching to Git - distributed version control. This intro to Git covers the basics, from cloning to pushing for beginners.

version controlvcsgit
Why Git?
Distributed
–

Local repo

–

With entire dev history

–

Off-line work

–

Remote sync
Why Git?
Non-linear
–

Rapid branching and merging

–

merging more often than writing

–

passing around various reviewers
Why Git?
Scale
–

Efficient handling of large projects

–

Fast

–

scalable
Git VS Subversion
Git is not better than Subversion. But is also not worse. It's different.
The key difference is that it is decentralized. Imagine you are a developer on the road, you
develop on your laptop and you want to have source control so that you can go back 3 hours.
With Subversion, you have a Problem: The SVN Repository may be in a location you can't reach
(in your company, and you don't have Internet at the moment), you cannot commit. If you want to
make a copy of your code, you have to literally copy/paste it.
With Git, you do not have this problem. Your local copy is a repository, and you can commit to it
and get all benefits of source control. When you regain connectivity to the main repository, you
can commit against it.
SVN: has the advantage that it's MUCH simpler to learn: There is your repository, all changes to
towards it, if you know how to create, commit and checkout and you're ready to go and can
pickup stuff like branching, update etc. later on.
Git: has the advantage that it's MUCH better suited if some developers are not always connected
to the master repository. Also, it's much faster than SVN. And from what I hear, branching and
merging support is a lot better (which is to be expected, as these are the core reasons it was
written).

http://stackoverflow.com/questions/871/why-is-git-better-than-subversion

Recommended for you

Introduction to Git/Github - A beginner's guide
Introduction to Git/Github - A beginner's guideIntroduction to Git/Github - A beginner's guide
Introduction to Git/Github - A beginner's guide

Introduction to Git/Github - A beginner's guide Agenda: Installing Git Introduction to Version Control Git Basics Creating a new local Git repository Cloning a Git repository Making use of Git commit history Reverting files to previous states Creating a Github Repository Adding, Committing & Pushing changes Branching Merging Branches Sending Pull Requests Conflict Resolution and 3 Exercises

developmenteducationalversion control
Git 101: Git and GitHub for Beginners
Git 101: Git and GitHub for Beginners Git 101: Git and GitHub for Beginners
Git 101: Git and GitHub for Beginners

HubSpot Software Engineer Meghan Nelson created this intro to git and GitHub for a Women Who Code meetup.

software developmentgithubgit
Quick Introduction to git
Quick Introduction to gitQuick Introduction to git
Quick Introduction to git

Distributed version control with git provides a brief introduction to git. It discusses why git was created, what git is, the git object model of blobs, trees and commits, collaborating through local and remote repositories, branching and merging, and an overview of the basic git workflow. The document provides resources for learning more about git.

git
Basic Commands
●

Repository creation/Checkout

gi t i ni t ( I ni t i al i ze a r eposi t or y)
gi t c l one ( svn checkout )
Basic Commands
●

Daily routine

gi t s t at us ( Show t he wor ki ng t r ee st at us )
gi t add ( Add f i l e cont ent s t o t he i ndex )
gi t rm ( Rem
ove f i l es f r om t he wor ki ng t r ee
and f r om t he i ndex )
gi t c om i t ( Recor d changes t o t he r eposi t or y)
m
Basic Commands
●

Big Brother

gi t di f f ( Show changes bet ween com i t s,
m
com i t and wor ki ng t r ee, et c )
m
gi t bl am ( Show what r evi si on and aut hor l ast
e
m
odi f i ed each l i ne of a f i l e )
gi t bi s ec t ( Fi nd by bi nar y sear ch t he change
t hat i nt r oduced a bug)
Branching & Merging
●

branch & merge
–

Extremely fast

–

keep your room clean

–

Try new things

Recommended for you

Git 1
Git 1Git 1
Git 1

This document provides an overview and introduction to using the version control system Git. It begins with explaining what version control is and why it is useful for collaboration, storing versions, restoring previous versions, understanding changes, and backup. It then discusses using Git from the command line versus a GUI. The remainder of the document outlines Git's basic workflow, including configuring Git, committing related changes with good commit messages, using branches extensively, never committing half-done work by using stash, keeping the remote in sync, and merging changes. It concludes by inviting the reader to join them in learning more about Git.

mashhadgitmashhadlug
Gitting better
Gitting betterGitting better
Gitting better

Getting a little bit better using Git. This presentation aims beginners for Git source control management.

gitbeginner
Git essential training & sharing self
Git essential training & sharing selfGit essential training & sharing self
Git essential training & sharing self

Git provides several advantages over SVN including faster operations, cheaper branching and merging, and a distributed model. It allows for multiple workflows including creating branches for experimental work or bug fixes. Commits, trees, blobs, and tags provide integrity for file versions and changes. Pull requests enable collaboration across remote repositories. Migrating to Git from SVN and using tools like SubGit can help transition repositories.

gitdevopscontinuous integration
Branching & Merging
Branch best practices
–

Follow Vincent Driessen's branching model
Driessen

–

Don’t directly work on master or Develop
Typical Workflow
1.New Branch
2.Coding
3.Commit
4.Push
Typical Workflow
1.New Branch
2.Coding
3.Commit

$ git branch myNewBranch
$ git checkout myNewBranch
------------Or-----------$ git checkout -b myNewBranch

$ git status
# On branch myNewBranch
# Untracked files:
#
#
MyNewFile.php
#
MyNewFile2.php
$ git add MyNewFile.php MyNewFile2.php
------------Or-----------$ git add .
$ git commit -m 'MyCommitMessage'

4.Push

$ git push origin myNewBranch
Question?

Recommended for you

3 Git
3 Git3 Git
3 Git

The Information Technology have led us into an era where the production, sharing and use of information are now part of everyday life and of which we are often unaware actors almost: it is now almost inevitable not leave a digital trail of many of the actions we do every day; for example, by digital content such as photos, videos, blog posts and everything that revolves around the social networks (Facebook and Twitter in particular). Added to this is that with the "internet of things", we see an increase in devices such as watches, bracelets, thermostats and many other items that are able to connect to the network and therefore generate large data streams. This explosion of data justifies the birth, in the world of the term Big Data: it indicates the data produced in large quantities, with remarkable speed and in different formats, which requires processing technologies and resources that go far beyond the conventional systems management and storage of data. It is immediately clear that, 1) models of data storage based on the relational model, and 2) processing systems based on stored procedures and computations on grids are not applicable in these contexts. As regards the point 1, the RDBMS, widely used for a great variety of applications, have some problems when the amount of data grows beyond certain limits. The scalability and cost of implementation are only a part of the disadvantages: very often, in fact, when there is opposite to the management of big data, also the variability, or the lack of a fixed structure, represents a significant problem. This has given a boost to the development of the NoSQL database. The website NoSQL Databases defines NoSQL databases such as "Next Generation Databases mostly addressing some of the points: being non-relational, distributed, open source and horizontally scalable." These databases are: distributed, open source, scalable horizontally, without a predetermined pattern (key-value, column-oriented, document-based and graph-based), easily replicable, devoid of the ACID and can handle large amounts of data. These databases are integrated or integrated with processing tools based on the MapReduce paradigm proposed by Google in 2009. MapReduce with the open source Hadoop framework represent the new model for distributed processing of large amounts of data that goes to supplant techniques based on stored procedures and computational grids (step 2). The relational model taught courses in basic database design, has many limitations compared to the demands posed by new applications based on Big Data and NoSQL databases that use to store data and MapReduce to process large amounts of data. Course Website http://pbdmng.datatoknowledge.it/ Contact me to download the slides

git
Git tips
Git tipsGit tips
Git tips

This document discusses Git tips and best practices, including: - Git is a distributed version control system designed for speed, integrity and distributed workflows. It stores snapshots of project files rather than file differences. - Merging incorporates changes from one branch into another but leaves an extra merge commit, while rebasing replays changes to a new base and cleans up history. - A successful Git branching model uses main branches like master and develop, and supporting branches like features, releases and hotfixes to integrate work.

git
Lets git to it
Lets git to itLets git to it
Lets git to it

This document provides an introduction to Git and common branching models. It begins by defining Git as a distributed revision control system created by Linus Torvalds for Linux kernel development. It then discusses why Git is useful, how it is distributed and optimized for merging, and some key Git concepts like commits, branches, and the local repository structure. The document also outlines common Git commands, workflows like centralized, feature branching, Gitflow and GitHub flow, and how pull requests enable collaboration. It concludes by listing additional Git learning resources.

gitintroduction

More Related Content

Viewers also liked

Enough with the JavaScript already!
Enough with the JavaScript already!Enough with the JavaScript already!
Enough with the JavaScript already!
Nicholas Zakas
 
Intro To Git
Intro To GitIntro To Git
Intro To Git
kyleburton
 
Git Presentation
Git PresentationGit Presentation
Git Presentation
Prem Aseem Jain
 
Basic Git Intro
Basic Git IntroBasic Git Intro
Basic Git Intro
Yoad Snapir
 
Introduction to git
Introduction to gitIntroduction to git
Introduction to git
Randal Schwartz
 
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
Geoff Hoffman
 
Introduction to Git/Github - A beginner's guide
Introduction to Git/Github - A beginner's guideIntroduction to Git/Github - A beginner's guide
Introduction to Git/Github - A beginner's guide
Rohit Arora
 
Git 101: Git and GitHub for Beginners
Git 101: Git and GitHub for Beginners Git 101: Git and GitHub for Beginners
Git 101: Git and GitHub for Beginners
HubSpot
 
Quick Introduction to git
Quick Introduction to gitQuick Introduction to git
Quick Introduction to git
Joel Krebs
 

Viewers also liked (9)

Enough with the JavaScript already!
Enough with the JavaScript already!Enough with the JavaScript already!
Enough with the JavaScript already!
 
Intro To Git
Intro To GitIntro To Git
Intro To Git
 
Git Presentation
Git PresentationGit Presentation
Git Presentation
 
Basic Git Intro
Basic Git IntroBasic Git Intro
Basic Git Intro
 
Introduction to git
Introduction to gitIntroduction to git
Introduction to git
 
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
 
Introduction to Git/Github - A beginner's guide
Introduction to Git/Github - A beginner's guideIntroduction to Git/Github - A beginner's guide
Introduction to Git/Github - A beginner's guide
 
Git 101: Git and GitHub for Beginners
Git 101: Git and GitHub for Beginners Git 101: Git and GitHub for Beginners
Git 101: Git and GitHub for Beginners
 
Quick Introduction to git
Quick Introduction to gitQuick Introduction to git
Quick Introduction to git
 

Similar to Git presentation

Git 1
Git 1Git 1
Gitting better
Gitting betterGitting better
Gitting better
Ali Servet Donmez
 
Git essential training & sharing self
Git essential training & sharing selfGit essential training & sharing self
Git essential training & sharing self
Chen-Tien Tsai
 
3 Git
3 Git3 Git
Git tips
Git tipsGit tips
Git tips
Arthur Shvetsov
 
Lets git to it
Lets git to itLets git to it
Lets git to it
Yoram Michaeli
 
Wokshop de Git
Wokshop de Git Wokshop de Git
Wokshop de Git
Alberto Leal
 
Git
GitGit
Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)
Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)
Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)
GDSCNiT
 
Git basics
Git basicsGit basics
Git basics
GHARSALLAH Mohamed
 
Using Git with WordPress - Presented by Nigel Rodgers.
Using Git with WordPress - Presented by Nigel Rodgers.Using Git with WordPress - Presented by Nigel Rodgers.
Using Git with WordPress - Presented by Nigel Rodgers.
WordCamp Harare
 
Managing e commerce systems codebase with git
Managing e commerce systems codebase with gitManaging e commerce systems codebase with git
Managing e commerce systems codebase with git
Bruno Ricardo Siqueira
 
True Git
True Git True Git
True Git
colleenfry
 
Git 101: Force-sensitive to Jedi padawan
Git 101: Force-sensitive to Jedi padawanGit 101: Force-sensitive to Jedi padawan
Git 101: Force-sensitive to Jedi padawan
James Ford
 
Open Source_Git.pptx
Open Source_Git.pptxOpen Source_Git.pptx
Open Source_Git.pptx
Muhammad Sohail
 
Version Control ThinkVitamin
Version Control ThinkVitaminVersion Control ThinkVitamin
Version Control ThinkVitamin
Alex Hillman
 
Getting Started with Git and GitHub
Getting Started with Git and GitHubGetting Started with Git and GitHub
Getting Started with Git and GitHub
Rabiraj Khadka
 
Git introduction
Git introductionGit introduction
Git introduction
Ivan Adhi Prasetya
 
Git in a nutshell
Git in a nutshellGit in a nutshell
Git in a nutshell
Pranesh Vittal
 
Git workshop
Git workshopGit workshop
Git workshop
Ray Toal
 

Similar to Git presentation (20)

Git 1
Git 1Git 1
Git 1
 
Gitting better
Gitting betterGitting better
Gitting better
 
Git essential training & sharing self
Git essential training & sharing selfGit essential training & sharing self
Git essential training & sharing self
 
3 Git
3 Git3 Git
3 Git
 
Git tips
Git tipsGit tips
Git tips
 
Lets git to it
Lets git to itLets git to it
Lets git to it
 
Wokshop de Git
Wokshop de Git Wokshop de Git
Wokshop de Git
 
Git
GitGit
Git
 
Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)
Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)
Open Sprintera (Where Open Source Sparks a Sprint of Possibilities)
 
Git basics
Git basicsGit basics
Git basics
 
Using Git with WordPress - Presented by Nigel Rodgers.
Using Git with WordPress - Presented by Nigel Rodgers.Using Git with WordPress - Presented by Nigel Rodgers.
Using Git with WordPress - Presented by Nigel Rodgers.
 
Managing e commerce systems codebase with git
Managing e commerce systems codebase with gitManaging e commerce systems codebase with git
Managing e commerce systems codebase with git
 
True Git
True Git True Git
True Git
 
Git 101: Force-sensitive to Jedi padawan
Git 101: Force-sensitive to Jedi padawanGit 101: Force-sensitive to Jedi padawan
Git 101: Force-sensitive to Jedi padawan
 
Open Source_Git.pptx
Open Source_Git.pptxOpen Source_Git.pptx
Open Source_Git.pptx
 
Version Control ThinkVitamin
Version Control ThinkVitaminVersion Control ThinkVitamin
Version Control ThinkVitamin
 
Getting Started with Git and GitHub
Getting Started with Git and GitHubGetting Started with Git and GitHub
Getting Started with Git and GitHub
 
Git introduction
Git introductionGit introduction
Git introduction
 
Git in a nutshell
Git in a nutshellGit in a nutshell
Git in a nutshell
 
Git workshop
Git workshopGit workshop
Git workshop
 

Recently uploaded

BT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdf
BT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdfBT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdf
BT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdf
Neo4j
 
What's New in Copilot for Microsoft365 May 2024.pptx
What's New in Copilot for Microsoft365 May 2024.pptxWhat's New in Copilot for Microsoft365 May 2024.pptx
What's New in Copilot for Microsoft365 May 2024.pptx
Stephanie Beckett
 
The Rise of Supernetwork Data Intensive Computing
The Rise of Supernetwork Data Intensive ComputingThe Rise of Supernetwork Data Intensive Computing
The Rise of Supernetwork Data Intensive Computing
Larry Smarr
 
Implementations of Fused Deposition Modeling in real world
Implementations of Fused Deposition Modeling  in real worldImplementations of Fused Deposition Modeling  in real world
Implementations of Fused Deposition Modeling in real world
Emerging Tech
 
Measuring the Impact of Network Latency at Twitter
Measuring the Impact of Network Latency at TwitterMeasuring the Impact of Network Latency at Twitter
Measuring the Impact of Network Latency at Twitter
ScyllaDB
 
Research Directions for Cross Reality Interfaces
Research Directions for Cross Reality InterfacesResearch Directions for Cross Reality Interfaces
Research Directions for Cross Reality Interfaces
Mark Billinghurst
 
[Talk] Moving Beyond Spaghetti Infrastructure [AOTB] 2024-07-04.pdf
[Talk] Moving Beyond Spaghetti Infrastructure [AOTB] 2024-07-04.pdf[Talk] Moving Beyond Spaghetti Infrastructure [AOTB] 2024-07-04.pdf
[Talk] Moving Beyond Spaghetti Infrastructure [AOTB] 2024-07-04.pdf
Kief Morris
 
INDIAN AIR FORCE FIGHTER PLANES LIST.pdf
INDIAN AIR FORCE FIGHTER PLANES LIST.pdfINDIAN AIR FORCE FIGHTER PLANES LIST.pdf
INDIAN AIR FORCE FIGHTER PLANES LIST.pdf
jackson110191
 
How RPA Help in the Transportation and Logistics Industry.pptx
How RPA Help in the Transportation and Logistics Industry.pptxHow RPA Help in the Transportation and Logistics Industry.pptx
How RPA Help in the Transportation and Logistics Industry.pptx
SynapseIndia
 
Active Inference is a veryyyyyyyyyyyyyyyyyyyyyyyy
Active Inference is a veryyyyyyyyyyyyyyyyyyyyyyyyActive Inference is a veryyyyyyyyyyyyyyyyyyyyyyyy
Active Inference is a veryyyyyyyyyyyyyyyyyyyyyyyy
RaminGhanbari2
 
Password Rotation in 2024 is still Relevant
Password Rotation in 2024 is still RelevantPassword Rotation in 2024 is still Relevant
Password Rotation in 2024 is still Relevant
Bert Blevins
 
Best Programming Language for Civil Engineers
Best Programming Language for Civil EngineersBest Programming Language for Civil Engineers
Best Programming Language for Civil Engineers
Awais Yaseen
 
Mitigating the Impact of State Management in Cloud Stream Processing Systems
Mitigating the Impact of State Management in Cloud Stream Processing SystemsMitigating the Impact of State Management in Cloud Stream Processing Systems
Mitigating the Impact of State Management in Cloud Stream Processing Systems
ScyllaDB
 
Quality Patents: Patents That Stand the Test of Time
Quality Patents: Patents That Stand the Test of TimeQuality Patents: Patents That Stand the Test of Time
Quality Patents: Patents That Stand the Test of Time
Aurora Consulting
 
20240704 QFM023 Engineering Leadership Reading List June 2024
20240704 QFM023 Engineering Leadership Reading List June 202420240704 QFM023 Engineering Leadership Reading List June 2024
20240704 QFM023 Engineering Leadership Reading List June 2024
Matthew Sinclair
 
Coordinate Systems in FME 101 - Webinar Slides
Coordinate Systems in FME 101 - Webinar SlidesCoordinate Systems in FME 101 - Webinar Slides
Coordinate Systems in FME 101 - Webinar Slides
Safe Software
 
WhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdf
WhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdfWhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdf
WhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdf
ArgaBisma
 
20240702 QFM021 Machine Intelligence Reading List June 2024
20240702 QFM021 Machine Intelligence Reading List June 202420240702 QFM021 Machine Intelligence Reading List June 2024
20240702 QFM021 Machine Intelligence Reading List June 2024
Matthew Sinclair
 
Recent Advancements in the NIST-JARVIS Infrastructure
Recent Advancements in the NIST-JARVIS InfrastructureRecent Advancements in the NIST-JARVIS Infrastructure
Recent Advancements in the NIST-JARVIS Infrastructure
KAMAL CHOUDHARY
 
Best Practices for Effectively Running dbt in Airflow.pdf
Best Practices for Effectively Running dbt in Airflow.pdfBest Practices for Effectively Running dbt in Airflow.pdf
Best Practices for Effectively Running dbt in Airflow.pdf
Tatiana Al-Chueyr
 

Recently uploaded (20)

BT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdf
BT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdfBT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdf
BT & Neo4j: Knowledge Graphs for Critical Enterprise Systems.pptx.pdf
 
What's New in Copilot for Microsoft365 May 2024.pptx
What's New in Copilot for Microsoft365 May 2024.pptxWhat's New in Copilot for Microsoft365 May 2024.pptx
What's New in Copilot for Microsoft365 May 2024.pptx
 
The Rise of Supernetwork Data Intensive Computing
The Rise of Supernetwork Data Intensive ComputingThe Rise of Supernetwork Data Intensive Computing
The Rise of Supernetwork Data Intensive Computing
 
Implementations of Fused Deposition Modeling in real world
Implementations of Fused Deposition Modeling  in real worldImplementations of Fused Deposition Modeling  in real world
Implementations of Fused Deposition Modeling in real world
 
Measuring the Impact of Network Latency at Twitter
Measuring the Impact of Network Latency at TwitterMeasuring the Impact of Network Latency at Twitter
Measuring the Impact of Network Latency at Twitter
 
Research Directions for Cross Reality Interfaces
Research Directions for Cross Reality InterfacesResearch Directions for Cross Reality Interfaces
Research Directions for Cross Reality Interfaces
 
[Talk] Moving Beyond Spaghetti Infrastructure [AOTB] 2024-07-04.pdf
[Talk] Moving Beyond Spaghetti Infrastructure [AOTB] 2024-07-04.pdf[Talk] Moving Beyond Spaghetti Infrastructure [AOTB] 2024-07-04.pdf
[Talk] Moving Beyond Spaghetti Infrastructure [AOTB] 2024-07-04.pdf
 
INDIAN AIR FORCE FIGHTER PLANES LIST.pdf
INDIAN AIR FORCE FIGHTER PLANES LIST.pdfINDIAN AIR FORCE FIGHTER PLANES LIST.pdf
INDIAN AIR FORCE FIGHTER PLANES LIST.pdf
 
How RPA Help in the Transportation and Logistics Industry.pptx
How RPA Help in the Transportation and Logistics Industry.pptxHow RPA Help in the Transportation and Logistics Industry.pptx
How RPA Help in the Transportation and Logistics Industry.pptx
 
Active Inference is a veryyyyyyyyyyyyyyyyyyyyyyyy
Active Inference is a veryyyyyyyyyyyyyyyyyyyyyyyyActive Inference is a veryyyyyyyyyyyyyyyyyyyyyyyy
Active Inference is a veryyyyyyyyyyyyyyyyyyyyyyyy
 
Password Rotation in 2024 is still Relevant
Password Rotation in 2024 is still RelevantPassword Rotation in 2024 is still Relevant
Password Rotation in 2024 is still Relevant
 
Best Programming Language for Civil Engineers
Best Programming Language for Civil EngineersBest Programming Language for Civil Engineers
Best Programming Language for Civil Engineers
 
Mitigating the Impact of State Management in Cloud Stream Processing Systems
Mitigating the Impact of State Management in Cloud Stream Processing SystemsMitigating the Impact of State Management in Cloud Stream Processing Systems
Mitigating the Impact of State Management in Cloud Stream Processing Systems
 
Quality Patents: Patents That Stand the Test of Time
Quality Patents: Patents That Stand the Test of TimeQuality Patents: Patents That Stand the Test of Time
Quality Patents: Patents That Stand the Test of Time
 
20240704 QFM023 Engineering Leadership Reading List June 2024
20240704 QFM023 Engineering Leadership Reading List June 202420240704 QFM023 Engineering Leadership Reading List June 2024
20240704 QFM023 Engineering Leadership Reading List June 2024
 
Coordinate Systems in FME 101 - Webinar Slides
Coordinate Systems in FME 101 - Webinar SlidesCoordinate Systems in FME 101 - Webinar Slides
Coordinate Systems in FME 101 - Webinar Slides
 
WhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdf
WhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdfWhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdf
WhatsApp Image 2024-03-27 at 08.19.52_bfd93109.pdf
 
20240702 QFM021 Machine Intelligence Reading List June 2024
20240702 QFM021 Machine Intelligence Reading List June 202420240702 QFM021 Machine Intelligence Reading List June 2024
20240702 QFM021 Machine Intelligence Reading List June 2024
 
Recent Advancements in the NIST-JARVIS Infrastructure
Recent Advancements in the NIST-JARVIS InfrastructureRecent Advancements in the NIST-JARVIS Infrastructure
Recent Advancements in the NIST-JARVIS Infrastructure
 
Best Practices for Effectively Running dbt in Airflow.pdf
Best Practices for Effectively Running dbt in Airflow.pdfBest Practices for Effectively Running dbt in Airflow.pdf
Best Practices for Effectively Running dbt in Airflow.pdf
 

Git presentation

  • 2. Agenda ● Git introduction ● Why Git? ● Git VS Subversion ● Basic Commands ● Branching & Merging ● Typical Workflow
  • 3. Git introduction ● Distributed Version Control System ● Speed & Efficiency ● Decentralized
  • 5. Why Git? Distributed – Local repo – With entire dev history – Off-line work – Remote sync
  • 6. Why Git? Non-linear – Rapid branching and merging – merging more often than writing – passing around various reviewers
  • 7. Why Git? Scale – Efficient handling of large projects – Fast – scalable
  • 8. Git VS Subversion Git is not better than Subversion. But is also not worse. It's different. The key difference is that it is decentralized. Imagine you are a developer on the road, you develop on your laptop and you want to have source control so that you can go back 3 hours. With Subversion, you have a Problem: The SVN Repository may be in a location you can't reach (in your company, and you don't have Internet at the moment), you cannot commit. If you want to make a copy of your code, you have to literally copy/paste it. With Git, you do not have this problem. Your local copy is a repository, and you can commit to it and get all benefits of source control. When you regain connectivity to the main repository, you can commit against it. SVN: has the advantage that it's MUCH simpler to learn: There is your repository, all changes to towards it, if you know how to create, commit and checkout and you're ready to go and can pickup stuff like branching, update etc. later on. Git: has the advantage that it's MUCH better suited if some developers are not always connected to the master repository. Also, it's much faster than SVN. And from what I hear, branching and merging support is a lot better (which is to be expected, as these are the core reasons it was written). http://stackoverflow.com/questions/871/why-is-git-better-than-subversion
  • 9. Basic Commands ● Repository creation/Checkout gi t i ni t ( I ni t i al i ze a r eposi t or y) gi t c l one ( svn checkout )
  • 10. Basic Commands ● Daily routine gi t s t at us ( Show t he wor ki ng t r ee st at us ) gi t add ( Add f i l e cont ent s t o t he i ndex ) gi t rm ( Rem ove f i l es f r om t he wor ki ng t r ee and f r om t he i ndex ) gi t c om i t ( Recor d changes t o t he r eposi t or y) m
  • 11. Basic Commands ● Big Brother gi t di f f ( Show changes bet ween com i t s, m com i t and wor ki ng t r ee, et c ) m gi t bl am ( Show what r evi si on and aut hor l ast e m odi f i ed each l i ne of a f i l e ) gi t bi s ec t ( Fi nd by bi nar y sear ch t he change t hat i nt r oduced a bug)
  • 12. Branching & Merging ● branch & merge – Extremely fast – keep your room clean – Try new things
  • 13. Branching & Merging Branch best practices – Follow Vincent Driessen's branching model Driessen – Don’t directly work on master or Develop
  • 15. Typical Workflow 1.New Branch 2.Coding 3.Commit $ git branch myNewBranch $ git checkout myNewBranch ------------Or-----------$ git checkout -b myNewBranch $ git status # On branch myNewBranch # Untracked files: # # MyNewFile.php # MyNewFile2.php $ git add MyNewFile.php MyNewFile2.php ------------Or-----------$ git add . $ git commit -m 'MyCommitMessage' 4.Push $ git push origin myNewBranch