Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Git: The fast version control system
Search
Gustavo Barbosa
August 01, 2012
Programming
250
0
Share
Git: The fast version control system
A talk about git given to my colleagues at Quatix.
Gustavo Barbosa
August 01, 2012
More Decks by Gustavo Barbosa
See All by Gustavo Barbosa
Arquitetura de Apps em Cenários Offline
barbosa
2
370
Diet View Controllers
barbosa
0
230
CocoaPods: The dependency manager for Objective-C projects
barbosa
0
65
Parse
barbosa
0
140
Introduction to Object
barbosa
0
68
git-flow: a successful branching model
barbosa
4
98
Clean Code
barbosa
0
140
Other Decks in Programming
See All in Programming
mruby on C#: From VM Implementation to Game Scripting (RubyKaigi 2026)
hadashia
2
1.5k
AIと共に生きる技術選定 2026
sgash708
0
120
ローカルLLMでどこまでコードが書けるか / How much code can be written on a local LLM
kishida
2
250
過去のレビュー知見をSkillsで資産化した話
pkshadeck
PRO
0
750
Liberating Ruby's Parser from Lexer Hacks
ydah
2
2.6k
ソフトウェア設計の結合バランス #phperkaigi
kajitack
0
490
「Linuxサーバー構築標準教科書」を読んでみた #ツナギメオフライン.7
akase244
0
1.4k
ハーネスエンジニアリングとは?
kinopeee
13
6.7k
ハーネスエンジニアリングにどう向き合うか 〜ルールファイルを超えて開発プロセスを設計する〜 / How to approach harness engineering
rkaga
27
19k
AIを導入する前にやるべきこと
negima
2
320
GNU Makeの使い方 / How to use GNU Make
kaityo256
PRO
16
5.6k
Spec Driven Development | AI Summit Vilnius
danielsogl
PRO
1
130
Featured
See All Featured
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
32
3k
How People are Using Generative and Agentic AI to Supercharge Their Products, Projects, Services and Value Streams Today
helenjbeal
1
170
Designing for humans not robots
tammielis
254
26k
How STYLIGHT went responsive
nonsquared
100
6.1k
The Pragmatic Product Professional
lauravandoore
37
7.2k
Music & Morning Musume
bryan
47
7.2k
Leadership Guide Workshop - DevTernity 2021
reverentgeek
1
280
Reflections from 52 weeks, 52 projects
jeffersonlam
356
21k
Build The Right Thing And Hit Your Dates
maggiecrowley
39
3.1k
Navigating Algorithm Shifts & AI Overviews - #SMXNext
aleyda
1
1.2k
[RailsConf 2023] Rails as a piece of cake
palkan
59
6.5k
The SEO Collaboration Effect
kristinabergwall1
1
440
Transcript
git the fast version control system
pull pull pull pull pull pull push push push
getting and creating projects
config configuring your git environment
$ git config --global user.name “Your Name” $ git config
--global user.email “
[email protected]
”
$ git config --global alias.st status $ git config --global
alias.ci commit $ git config --global alias.co checkout $ git config --global alias.br branch
$ git config --global color.ui auto
$ git config --global apply.whitespace nowarn
$ git config --global core.editor “mate -w”
~/.gitconfig
init initializes a directory as a git repository
None
None
None
.! |-- COMMIT_EDITMSG! |-- FETCH_HEAD! |-- HEAD! |-- ORIG_HEAD! |--
branches! |-- config! |-- description! |-- hooks! | |-- applypatch-msg! | |-- commit-msg! | |-- post-commit! | |-- post-receive! | |-- post-update! | |-- pre-applypatch! | |-- pre-commit! | |-- pre-rebase! | |-- prepare-commit-msg! | `-- update! |-- index! |-- info! | `-- exclude! |-- logs! | |-- HEAD! | `-- refs! |-- objects! `-- refs! |-- heads! |-- remotes! |-- stash! `-- tags
clone copy a git repository
None
None
basic snapshotting
add adds file contents to the staging area
None
None
None
None
status view the status of your files in the working
directory and staging area
None
None
diff shows diff of what is staged and what is
modified but unstaged
None
None
commit records a snapshot of the staging area
None
None
$ git commit -m ‘Fix commit msg’ --amend
reset
None
$ git reset --hard
$ git clean -df clean.requireForce defaults to true
rm remove files from the staging area
None
None
! mv rename files in the staging area
None
None
! stash saving temporarily local changes
None
None
branching and merging
branch list, create and manage working contexts
None
None
None
None
None
checkout
$ git checkout <branch> $ git checkout <tag> $ git
checkout <commit> $ git checkout <file>
merge merge a branch context into your current branch
None
None
None
None
None
log show commit history of a branch
None
None
None
None
None
None
None
tag tag a point in history as important
None
None
None
None
sharing and updating projects
remote list, add and delete remote repository aliases
None
None
fetch, pull
$ git fetch <repo> ! $ git fetch --all Download
objects and refs from another repository
$ git pull <repo> <branch>
push
$ git push <repo> <branch>
$ git push <repo> :<branch>
patch
$ git format-patch master --stdout > fix_bug.patch
None
$ git diff HEAD~1 > fix_bug.patch $ git apply fix_bug.patch
rebase
merge vs rebase
merge rebase
reordering commits
$ git rebase -i HEAD~3
None
$ git pull --rebase
$ git config branch.master.rebase true $ git config branch.branch3.rebase true
$ git config branch.autosetuprebase always ! $ git pull --no-rebase
None
None
$ git rebase --continue $ git rebase --abort
inspection and comparison
log
None
None
None
None
$ git rev-list
diff
None
None
None
None
None
None
None
git the fast version control system • http:/ /git-scm.com/ •
http:/ /gitready.com/ • http:/ /gitref.org/ • http:/ /github.com/ • http:/ /bitbucket.org/ • http:/ /progit.org/ • http:/ /stackoverflow.com/ • http:/ /www.arthurkoziel.com/2008/05/02/git-configuration/ • http:/ /www.iconfinder.com/