![Page 1: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/1.jpg)
GitGitHub Hub for Geographersfor Geographers@jgravois
@patrickarlt
slides: http://bit.ly/2oSd7Wx
![Page 2: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/2.jpg)
How is this going to work?How is this going to work?1. code2. A brief introduction3. In situ demo
![Page 4: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/4.jpg)
�le hostingchange archivingcommunication tool
![Page 5: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/5.jpg)
what what isis Git? Git?distributed version control
similar to replicated SDE versioning
![Page 6: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/6.jpg)
lets get collaborating!lets get collaborating!
![Page 7: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/7.jpg)
pat �nds a cool pat �nds a cool project projectopen sourceopen sourcehttps://github.com/jgravois/sandbox
GitHub: Fork A Repo
![Page 8: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/8.jpg)
pat creates his own pat creates his own of the of theprojectproject
forkfork
another repo hosted on github.com
git is distributed, each repo is a node in the graph
![Page 9: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/9.jpg)
pat pat clonesclones the repository the repositorycopys it onto his computer
git clone https://github.com/patrickarlt/sandbox.git
this creates another repo on pat's computer, another node in the graph
![Page 10: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/10.jpg)
pat creates a pat creates a branchbranchto store his own work
git checkout -b updates
Branches in a NutshellBasic Branching and MergingAtlassian: Using BranchesUnderstanding the GitHub Flow
![Page 11: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/11.jpg)
pat pat commitscommits in the new branch in the new branchto save his edits
git commit -am "update friends.geojson"
![Page 12: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/12.jpg)
pat pat pushespushes the branch up to his fork the branch up to his forkgit push origin updates
![Page 13: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/13.jpg)
then pat creates a then pat creates a pull requestpull requestto propose that john incorporate his work too
Creating a pull requestUnderstanding the GitHub Flow
![Page 14: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/14.jpg)
john john mergesmerges the pull request! the pull request!
![Page 15: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/15.jpg)
john makes his own commit directlyjohn makes his own commit directlyin GitHubin GitHub
![Page 16: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/16.jpg)
pat creates another pat creates another branchbranchto store more edits
git checkout -b more-updates
![Page 17: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/17.jpg)
and opens another pull requestand opens another pull request
![Page 18: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/18.jpg)
merge con�ict!merge con�ict!john edited the same line of the same �le
Resolve merge con�ict w/ command lineResolve merge con�ict on GitHub
![Page 19: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/19.jpg)
so pat so pat pullspulls from upstream from upstreamand resolves the con�ict manually
git pull upsteam master
![Page 20: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/20.jpg)
john has a suggestion for patjohn has a suggestion for pat
![Page 21: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/21.jpg)
so john uses github.com to make anso john uses github.com to make anedit of his ownedit of his own
![Page 22: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/22.jpg)
and opens a pull request for pat toand opens a pull request for pat toreviewreview
![Page 24: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/24.jpg)
teamwork makes the teamwork makes the dream workdream work!!
![Page 25: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/25.jpg)
resourcesresourcesTry Git! (Browser based)GitHub FlowAtlassian: Learning GitGitHub GuidesGit Documentation
![Page 26: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/26.jpg)
please, please, please �ll out a session survey
1. download the Esri Events App2. select Dev Summit3. search for "Git/GitHub for Geographers"4. leave feedback!
![Page 27: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/27.jpg)
idea, question, issue, or success story?
/ @geogangster @patrickarlt
Slides: http://bit.ly/2oSd7Wx
![Page 28: f o r G eo g raphers - Esri...git checkout -b updates Branches in a Nutshell Basic Branching and Merging Atlassian: Using Branches Understanding the GitHub Flow pat com mits in the](https://reader030.vdocuments.mx/reader030/viewer/2022011923/6057b98fe221104e364c8a02/html5/thumbnails/28.jpg)