Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
atomic commits
Search
Kai Howelmeyer
January 21, 2014
Research
140
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
atomic commits
Kai Howelmeyer
January 21, 2014
More Decks by Kai Howelmeyer
See All by Kai Howelmeyer
git tricks
kaihowl
3
160
git intro by mkilling
kaihowl
1
110
Other Decks in Research
See All in Research
生成AIなんでも展示会vol6 LT登壇資料 NexteraBERT
rikkabotan7
0
210
CDCL を用いた MILP の厳密解法
imai448
0
320
量子サマースクール2026「量子計算機アーキテクチャ分野の概観」
youten622
1
1k
Top 4セキュリティ会議に一通り論文が採択されるまでの道のりと展望 / Top 4 Security Grand Slam
takaomurakami
0
1.1k
La longévité des troupeaux laitiers: état des lieux et perspectives
institutdelelevage
PRO
0
140
OWASP AISVS - C7
shiell
2
860
全国町字単位空き家率推定データver1.0データ仕様
microbaseinc
0
320
【中間報告】国会議員の立法・政策実務を支える環境を巡る現状と課題
polipoli
0
870
ハードウェア研究で国際トップ会議を目指す!IROS 2027での論文採択を目指して
ayatokanada
7
4.1k
SPACE 2026 - Femmes en Elevage – Regards croisés desdifférentes filières
institutdelelevage
PRO
0
120
視覚若手の会LENSって何??
mickey_0226
0
400
Kaggle|AI Agent Security — しくじり先生、俺みたいになるな
pomcho555
1
130
Featured
See All Featured
Become a Pro
speakerdeck
PRO
31
6.3k
Efficient Content Optimization with Google Search Console & Apps Script
katarinadahlin
PRO
1
960
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
920
Groundhog Day: Seeking Process in Gaming for Health
codingconduct
0
450
How To Speak Unicorn (iThemes Webinar)
marktimemedia
1
620
Conquering PDFs: document understanding beyond plain text
inesmontani
PRO
4
3.3k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
17k
Design in an AI World
tapps
1
380
XXLCSS - How to scale CSS and keep your sanity
sugarenia
250
1.3M
Color Theory Basics | Prateek | Gurzu
gurzu
1
510
Leveraging Curiosity to Care for An Aging Population
cassininazir
1
550
The Curious Case for Waylosing
cassininazir
1
600
Transcript
atomic commits Kai Höwelmeyer @kaihowl git aficionados meetup 01/21/14
atomic commit A commit only containing changes that logically belong
together and cannot be split up any further without breaking the intent of the commit.
Keep the history clean. Convey intent. Don’t repeat the diff.
Features are seldom straight- forward. But your commits should be!
Dissect your feature into: Necessary changes & the actual feature
implementation
But how?
Commit early and often on a feature branch. It works
Fixed a typo Added a test Refactored a li6le Added another part Improved performance
When done, git merge -‐-‐squash on master
Master Commit 1 Master Commit 2 … Master Commit n Our enBre feature staged
Now git reset
Then git add -‐p Only choose hunks that belong
into one atomic commit. Master Commit 1 Master Commit 2 … Master Commit n Remainder unstaged Atomic Commit 1 staged
Check with git diff -‐-‐staged
Master Commit 1 Master Commit 2 … Master Commit n Remainder unstaged Atomic Commit 1 staged
Commit with meaningful message. Master Commit 1 …
Master Commit n Atomic Commit 1 Remainder unstaged
git stash -‐u Leaves clean working copy. Check integrity
of system. Master Commit 1 … Master Commit n Atomic Commit 1 Remainder stashed
git stash pop Stage next atomic commit with git
add -‐p Master Commit 1 … Master Commit n Atomic Commit 1 Remainder unstaged Atomic Commit 2 staged
Final check git diff ..feature-‐branch Did I commit
everything?
Next time Determine code ownership w/ log & blame -
or - How I fell in love with vim-fugitive
@kaihowl
Image Sources • http://www.flickr.com/photos/lij/ 122525716/sizes/l/ • http://www.flickr.com/photos/ diorama_sky/4557914779/sizes/l/ • http://www.flickr.com/photos/
camknows/3821001012/