Se ha denunciado esta presentación.
Se está descargando tu SlideShare. ×

Git - Bildiğiniz Gibi Değil

Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Próximo SlideShare
Git Sunumu
Git Sunumu
Cargando en…3
×

Eche un vistazo a continuación

1 de 85 Anuncio

Git - Bildiğiniz Gibi Değil

Descargar para leer sin conexión

Karabük Üniversitesi Programlama Günleri 2016'da gerçekleştirdiğim Git sunumu yansılarıdır.

These are the slides of my talk at Karabuk University Programming Days 2016. The slides are in Turkish.

Karabük Üniversitesi Programlama Günleri 2016'da gerçekleştirdiğim Git sunumu yansılarıdır.

These are the slides of my talk at Karabuk University Programming Days 2016. The slides are in Turkish.

Anuncio
Anuncio

Más Contenido Relacionado

A los espectadores también les gustó (20)

Similares a Git - Bildiğiniz Gibi Değil (20)

Anuncio

Más de Lemi Orhan Ergin (18)

Más reciente (15)

Anuncio

Git - Bildiğiniz Gibi Değil

  1. 1. GITbildiğiniz gibi değil…lemi orhan ergin
  2. 2. GIT bildiğiniz gibi değil… LEMİ ORHAN ERGİN Agile Software Craftsman, ACM 2001’den bu yana yazılım geliştiriyor Agile Turkey topluluk lideri Software Craftsmanship Turkey kurucusu Yazılımcı, Mimar, Eğitmen, Koç, Danışman 2009’dan bu yana GitMan Sony & eBay/GittiGidiyor eski çalışanı ACM’de yönetici ortak /lemiorhan lemiorhanergin.com @lemiorhan
  3. 3. Sürüm Yönetim Sistemleri dijital dosyalar için bir zaman makinesidir
  4. 4. Sürüm Kontrol Sistemleri Merkezi Yerel Dağıtık
  5. 5. Sadece dosya isimlerini kullanarak dosyaların sürümlerini belirler YEREL Sürüm Kontrol Sistemi
  6. 6. Revision Control System revizyonları yamalar halinde (patch) bir isimlendirme kuralına uygun şekilde saklar. http://en.wikipedia.org/wiki/Revision_Control_System YEREL Sürüm Kontrol Sistemi
  7. 7. merkezİ Sürüm Kontrol Sistemi Dosyaları ortak bir alanda saklar (sunucu) ve herkes buraya kendi kişisel makinalarından erişir (istemci)
  8. 8. merkezİ Sürüm Kontrol Sistemi Kullanıcılarda dosyaların sadece son sürümleri bulunur Eğer sunucu bozulursa, tüm sürümleri kaybetme ihtimali vardır
  9. 9. Sturgeon’nun Kuralı Der ki; bir işe yaramaz Yaptığımız şeylerin %90’ı İşe yarayan çözümleri bulabilmek için deneysel çalışmalar yapabileceğimiz, korkmadan sistemi dağıtabileceğimiz, güvenilir bir sisteme ihtiyaç vardır
  10. 10. Dağıtık Sürüm Kontrol Sistemi Her iki tipin avantajlarının birleşimi bir hibrit sistemdir
  11. 11. Dağıtık Sürüm Kontrol Sistemi Sunucuya erişim sorunlarına ve sunucudaki sürümlere bağımlılıktan endişe duymadan yerel değişiklikler yapabilmenizi sağlar
  12. 12. SVN gibi dağıtık olmayan sistemler Dosya farkları şeklinde
  13. 13. Git değişiklikleri farklı tutar Değişmiş dosyalar halinde
  14. 14. 2.7Gb 8.2Gb 450MB ? MOZILLA 350Mb kaynak kod İÇİN 1998’den bu yana yazılan Ne kadar bİR DİSK ALANI GEREKLİ
  15. 15. Git Ortami
  16. 16. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu .git Folder / Object Database
  17. 17. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu .git Folder / Object Database
  18. 18. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu .git Folder / Object Database
  19. 19. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu .git Folder / Object Database
  20. 20. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu .git Folder / Object Database
  21. 21. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu .git Folder / Object Database
  22. 22. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu .git Folder / Object Database
  23. 23. Sunucuya Kod Gönderme
  24. 24. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu .git Folder / Object Database
  25. 25. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu $ git add .git Folder / Object Database
  26. 26. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu $ git commit .git Folder / Object Database
  27. 27. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı .git Folder / Object Database Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu $ git push
  28. 28. Sunucudan Güncellemeleri Alma
  29. 29. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı .git Folder / Object Database Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu
  30. 30. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı .git Folder / Object Database Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu $ git fetch
  31. 31. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu $ git merge FETCH_HEAD .git Folder / Object Database
  32. 32. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu $ git pullKISAYOL .git Folder / Object Database
  33. 33. Kodu Sifirdan Alma
  34. 34. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu .git Folder / Object Database
  35. 35. Kaynak Kod Woking Copy Cache Staging Area / The Index Obje Veritabanı Uzak Depo Upstream Repo / Remote Repo Kendi makinamız Sunucu $ git cloneKISAYOL .git Folder / Object Database
  36. 36. Bir Grup Kod Değişikliği: Commit
  37. 37. Kaliningrad, Prussia’daki 7 köprü Yıl 1735
  38. 38. Königsberg, Prussia’daki 7 köprü Yıl 1735 Her bir köprüden bir kez geçerek tüm şehri dolaşabilir misiniz? Leonhard Euler
  39. 39. ÇİZGE TEORİSİ (Graph Theory)
  40. 40. klasör klasör klasör dosya dosya dosya
  41. 41. klasör klasör klasör dosya dosya dosya GIT bildiğiniz gibi değil… commit $ git add . $ git commit -m “first commit”
  42. 42. klasör klasör klasör dosya dosya dosya GIT bildiğiniz gibi değil… commit branch HEAD $ git add . $ git commit -m “first commit”
  43. 43. klasör klasör klasör dosya dosya dosya GIT bildiğiniz gibi değil… commit klasör klasör klasör dosya commit branch HEAD $ git add . $ git commit -m “second commit”
  44. 44. commit commit commit klasör klasör klasör dosya dosya dosya GIT bildiğiniz gibi değil… commit klasör klasör klasör dosya commit branch HEAD klasör dosya commit $ git add . $ git commit -m “third commit”
  45. 45. GIT bildiğiniz gibi değil… branch HEAD commit commit commit $ git add . $ git commit -m “third commit”
  46. 46. d99108a master HEAD $ git commit -m "first commit" [master (root-commit) d99108a] first commit 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 .gitignore
  47. 47. d99108a master HEADa4510bc $ git commit -m "second commit" [master a4510bc] second commit 1 file changed, 1 insertion(+)
  48. 48. d99108a master HEAD a4510bc b2be58f $ git commit -m "third commit" [master b2be58f] third commit 1 file changed, 1 insertion(+)
  49. 49. d99108a a4510bc b2be58f $ git commit -m "fourth commit" [master 8810ac4] fourth commit 1 file changed, 1 insertion(+) master HEAD8810ac4 Agh! Son commit’e bir değişiklik eklemeyi unutmuşum. Son commit’i değiştireyim. “ ”
  50. 50. d99108a a4510bc b2be58f $ git commit --amend [master 1fa3409] third commit 2 files changed, 1 insertion(+), 1 deletion(-) create mode 100644 readme.txt 1fa3409 Aynı ortak ata ile ilişkili 2. bir commit oluştu master HEAD8810ac4
  51. 51. d99108a a4510bc b2be58f 1fa3409 master HEAD 8810ac4 bb43c12 $ git commit -m "fifth commit" [master bb43c12] fifth commit 1 file changed, 1 insertion(+)
  52. 52. Ayni Anda Farkli Görevleri Gerçekleştirme
  53. 53. master HEAD
  54. 54. TAG/v1.1 $ git tag tag/v1.1 master HEAD
  55. 55. TAG/v1.1 master HEAD $ git commit
  56. 56. $ git branch typofix master HEAD typofixTAG/v1.1
  57. 57. $ git checkout typofix master typofixTAG/v1.1 HEAD
  58. 58. master HEAD typofix TAG/v1.1 $ git commit
  59. 59. master typofix TAG/v1.1 $ git checkout master HEAD
  60. 60. master HEAD TAG/v1.1 typofix $ git commit
  61. 61. master HEAD TAG/v1.1 typofix $ git merge typofix
  62. 62. master HEAD TAG/v1.1 $ git branch -d typofix
  63. 63. Kod Birleştirmenin Akillisi
  64. 64. master HEAD typofix TAG/v1.1
  65. 65. master HEAD typofix TAG/v1.1 $ git merge typofix
  66. 66. Başkalarinin Kodunu İle Entegrasyon
  67. 67. master HEAD TAG/v1.1 typofix
  68. 68. master HEAD TAG/v1.1 typofix $ git rebase master
  69. 69. Kaybolmayan Kod Sorunsali :)
  70. 70. master typofix TAG/v1.1 login HEAD
  71. 71. master TAG/v1.1 login HEAD $ git branch -D typofix
  72. 72. master typofix TAG/v1.1 login HEAD $ git branch typofix a45f3c
  73. 73. Cimbizla Kod Tirtiklamak
  74. 74. master HEAD TAG/v1.1 typofix
  75. 75. master HEAD TAG/v1.1 typofix $ git cherry-pick Green1 Green2
  76. 76. Hatalardan Geri Dönüş
  77. 77. master HEAD TAG/v1.1 typofix
  78. 78. master HEAD TAG/v1.1 typofix $ git reset HEAD~2
  79. 79. Commit Graph
  80. 80. commit branch checkout reset revert cherry-pick tag merge rebase stash fetch
  81. 81. LEMİ ORHAN ERGİN Master Software Craftsman, ACM /lemiorhan lemiorhanergin.com @lemiorhan

×