verzování
TRANSCRIPT
![Page 1: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/1.jpg)
VerzováníVerzováníFor The Win
Martin Zlámal
![Page 2: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/2.jpg)
$ whoami
GIT druid lvl. 65
ve firmě
@mrtnzlml
![Page 3: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/3.jpg)
píšu zlml.cz„Díky, to jsem přesně hledal!“
– Aleš M.
![Page 4: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/4.jpg)
Co je to verzování?
Praktická ukázka
123
Git intro
![Page 5: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/5.jpg)
Co si představujete pod pojmem
„verzování“ ?
![Page 6: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/6.jpg)
Potřebujete verzovat?
ANOANO
![Page 7: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/7.jpg)
Manuální správa verzí
Špatnácesta
![Page 8: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/8.jpg)
Lokální správa verzíSCCS (1972), RCS (1982), IntelliJ IDEA (2002 ?)
Lepší než nic. Ale to je skoro všechno...
![Page 9: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/9.jpg)
Centralizovaná správa verzíCVS (1986), CVSNT (1998), QVCS Enterprise (1998), SVN (2000)
Obrovský posun oproti lokálnímu VCS, ale...
![Page 10: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/10.jpg)
![Page 11: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/11.jpg)
Distribuovaná správa verzíDarcs (2002), Bazaar (2005), Git (2005), Mercurial (2005)
Další evoluce CVCS. Současný stav.
![Page 12: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/12.jpg)
![Page 13: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/13.jpg)
NextGen správa verzíDalší evoluce DVCS. Budoucí stav.
Důležité je uvědomit si, že i DVCS bude pravděpodobně jednou zastaralé.
Zatím ale není, takže...
![Page 14: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/14.jpg)
Git / t/ɡɪ • n. 1 a completely ignorant, childishperson with no manners.
![Page 15: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/15.jpg)
WorkingDirectory
PART 1
PRACOVNÍ ADRESÁŘ
![Page 16: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/16.jpg)
?ADRESÁŘ
![Page 17: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/17.jpg)
StagingArea
PART 2
OBLAST PŘIPRAVENÝCH ZMĚN
![Page 18: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/18.jpg)
ADRESÁŘ INDEX
git add <file>
git reset [HEAD <file>]
![Page 19: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/19.jpg)
RepositoryPART 3
LOKÁLNÍ REPOZITÁŘ
![Page 20: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/20.jpg)
git commit
git reset –-soft HEAD~git reset –-soft <hash>
ADRESÁŘ INDEX LOKÁLNÍREPO
git commit -a
![Page 21: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/21.jpg)
Krátké opakování$ git add file1.c file2.c$ git reset
$ git commit$ git reset –-soft HEAD~$ git commit -a -c ORIG_HEAD
![Page 22: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/22.jpg)
commit22d52564cd7b3f72a329f2c1684e3d5f7240ea45(tag: v2.1.5)Author: Martin Zlámal <[email protected]>Date: Sat Apr 23 17:50:17 2016 +0200
Fix extensions registration when there is no other extension closes #20
![Page 23: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/23.jpg)
Branching modelUkážu za chvíli...
![Page 24: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/24.jpg)
Synchronizace s remote
ORIGIN
LOCAL
git pull [--rebase]
git push[--tags]
git fetch
![Page 25: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/25.jpg)
DEMO TIMELoading...
![Page 26: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/26.jpg)
„The largest open source community in the world“
![Page 27: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/27.jpg)
Pro Git
Scott Chacon
![Page 28: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/28.jpg)
Dokážete jít proti davu?
antstudio.cz/kariera
![Page 29: Verzování](https://reader031.vdocuments.pub/reader031/viewer/2022030301/587fa11c1a28ab825e8b5ec9/html5/thumbnails/29.jpg)
Díky, to je vše.Díky, to je vše.ZLML.CZ @mrtnzlml