Git for Professionals Tutorial - Tools & Concepts for Mastering Version Control with Git

แชร์
ฝัง
  • เผยแพร่เมื่อ 15 พ.ค. 2024
  • Git has the power to make you a better software developer. But you'll have to go beyond the basic "commit, push, pull" to use it effectively! In this course, we'll look at some of the more advanced concepts and tools to make you more productive and confident with Git.
    This course focuses on using Git with the command line.
    ✏️ This course was created by Tobias Günther from Tower. You can download Tower's Git desktop UI here: www.git-tower.com
    ⭐️ Course Contents ⭐️
    ⌨️ (00:00) Introduction
    ⌨️ (00:52) Hosted by Tower
    ⌨️ (01:27) The perfect commit
    ⌨️ (08:07) Branching strategies
    ⌨️ (17:16) Pull requests
    ⌨️ (24:07) Merge conflicts
    ⌨️ (33:48) Merge vs. rebase
    ⌨️ (40:05) The Advanced Git Kit: www.git-tower.com/learn/git/a...
    Correction:
    23:37 Do NOT create a pull request to the Rails repo. This is just a demonstration and every frivolous PR creates extra work for their volunteer team.

ความคิดเห็น • 467

  • @tdew11
    @tdew11 2 ปีที่แล้ว +637

    Your voice was so relaxing it put me to sleep but when I woke up I knew how rebasing works, so thank you!

    • @coenfuse
      @coenfuse 2 ปีที่แล้ว +11

      Lmao

    • @ahmadjamalmughal47
      @ahmadjamalmughal47 2 ปีที่แล้ว

      😂

    • @nibbanapatipada9538
      @nibbanapatipada9538 2 ปีที่แล้ว

      same here!

    • @cokeantonio
      @cokeantonio 2 ปีที่แล้ว +6

      He sounds like christoph waltz. So soothing!

    • @Geddy107
      @Geddy107 2 ปีที่แล้ว +5

      @@cokeantonio Came to the comments just to see if someone else was thinking it.

  • @josephgutierrez8430
    @josephgutierrez8430 2 ปีที่แล้ว +227

    40 minutes sounds like a long time, but it was all jam packed with legitimate information and no fluff. Great video. Watched the whole thing and didn't even notice the time.

    • @KuroManX
      @KuroManX ปีที่แล้ว +2

      for me 40 min is when the guy is straight to the infos and not 5+ hours of beginner talk

    • @frk0788
      @frk0788 ปีที่แล้ว +1

      Yeah! that to me as well wondering why could it be, maybe the timing and pacing of the video is just fenomenal.

    • @vicLord-lh6ob
      @vicLord-lh6ob 3 หลายเดือนก่อน

      Indeed it was quality time

  • @fireballgfx
    @fireballgfx 2 ปีที่แล้ว +202

    I was not aware of the -p parameter who give me the ability to add only a specific part to the staging area.

    • @rxditay
      @rxditay 2 ปีที่แล้ว +4

      +1

    • @toihirhalim
      @toihirhalim 2 ปีที่แล้ว +5

      I had to cut, commit and then re-paste but now this powerful "-p" is awesome

    • @ahmadjamalmughal47
      @ahmadjamalmughal47 2 ปีที่แล้ว +1

      I swear me neither.

    • @depressedknight369
      @depressedknight369 2 ปีที่แล้ว

      really.. 😶

    • @vorrnth8734
      @vorrnth8734 2 ปีที่แล้ว +3

      I usually do that kind of stuff in git gui.

  • @OKBumble
    @OKBumble ปีที่แล้ว

    Bravo! Not only the action steps to complete certain actions, but "why" and an explanation of what actually happens when you do! Nicely done.

  • @zachsandvik1867
    @zachsandvik1867 2 ปีที่แล้ว +7

    My compliments to the speaker. You are a very good teacher. Speaking in a relaxed way makes listening to you a huge pleasure in following your explanations. Top!!!

  • @stevenschelling8452
    @stevenschelling8452 2 ปีที่แล้ว +14

    Phenomenal video. These types of dev tutorials can be so dry but you made it highly visible and explained things simply and clearly. Thanks!

  • @burgerchild
    @burgerchild ปีที่แล้ว +30

    This would have been an excellent 40 minute class in college. The knowledge is there in college, just spread out. this is clear and consise. Thanks for your work!

  • @vandana1145
    @vandana1145 2 ปีที่แล้ว +67

    The way you narrated the whole concept is so awesome, everything got stick to the mind perfectly. Thanks for this beautiful content.

  • @compScientizt
    @compScientizt 2 ปีที่แล้ว +3

    Thank you so much, Guru Ji💖🙏, You are an amazing teacher! You taught us so much useful information in such a short period and made it a lot easier to understand. Thanks a lot for providing us free education. I'm the greatest fan of your work and knowledge. Keep it up! 🙌 This is one of my most favorite channels on TH-cam 😍🥰

  • @cesarsalas6444
    @cesarsalas6444 10 หลายเดือนก่อน

    La forma en que narraste todo el concepto es tan increíble que todo se quedó perfectamente en la mente.

  • @pranayp1950
    @pranayp1950 2 ปีที่แล้ว +1

    Thank you so much for this man. Your content is a better than a lot of paid courses out there !

  • @talkohavy
    @talkohavy ปีที่แล้ว +203

    I consider myself as pretty profficiant with git,
    yet I'm doing this thing where i'm occasionally revisiting known technologies to maybe learn some new things.
    Anyhow, just I wanted to say that this 40-minutes long video was ALL WORTH IT just for the sake of learning about the git add with the -p flag to only mark some parts of a file to be included in the commit :) Love it! definitely gonna use it in the future♥ Thank you!

    • @s.i.m.c.a
      @s.i.m.c.a ปีที่แล้ว +2

      this is an introductory video, and "-p" flag is useless. As in the real work, most ppl uses temporary local branch with a logical name for each commit, thus no need to deal with staging or splitting commits especially in case of 50+ modified files.

    • @talkohavy
      @talkohavy ปีที่แล้ว +1

      @@s.i.m.c.a Plus, it doesn't work very well. Since posting this comment I tried using it, and man it sucks... sometimes it takes 2 or 3 rows and considers them as ONE CHANGE! Take it or leave it! When in fact each row is a chance on it's own, where I want only one of them. And yeah, the point you made is also valid. Haven't used it since. But it's nice to know all these "secret" git command. like git rerere for instance 😉

    • @dannnsss8034
      @dannnsss8034 ปีที่แล้ว

      Still so confused about rebase.

    • @Cameron655
      @Cameron655 ปีที่แล้ว

      @@dannnsss8034 Your're not the only person out here. I've read the documentation for "git rerere" a dozen times and I'm still confused. I mean, I use git every day, and I think I'm proficient, but there are some very dark corners.

    • @vladyslavkarpenko9372
      @vladyslavkarpenko9372 ปีที่แล้ว +1

      @@talkohavy Agree that git add - p not so useful, but just because it's command line interface makes harder to work out staging line by line instead of by blocks of code.
      Remember a lot of an optional "one letter" decisions in the interactive prompt? In this video the author just skips explanation of all options to just yES (accept incoming block of changes to stage) and nO (do not stage this whole block).
      The most IDEs (e. g. VS Code) gives you a useful interface to actually select which lines you would like to stage on commit. Of course sometimes happens that you needed to stage only partial change of the line, but that rare cases. In that situation you may modify line to one state, stage it and after that reimplement partial change that must be separated.

  • @architjain6749
    @architjain6749 2 ปีที่แล้ว +16

    "You can live a happy Git life just using merge", I felt it!

    • @MarcinScholke
      @MarcinScholke หลายเดือนก่อน

      as long as no conflicts are there

  • @codefacileWK
    @codefacileWK 2 ปีที่แล้ว +4

    Thank you for this amazing course ! Perfect narration !

  • @erikgrundy
    @erikgrundy 2 ปีที่แล้ว +3

    I'm quite a big fan of "git add -i". This lets you do all the hunk-specific addition, while avoiding having to retype commands

  • @karansmittal
    @karansmittal 2 ปีที่แล้ว

    The video on branching and now this video. Thank you so much for making these difficult concepts easy for me.

  • @meiyachan8483
    @meiyachan8483 2 ปีที่แล้ว +3

    Well presented and well explained! Clarified my long-time confusion of merge and rebase

  • @ashley_engle
    @ashley_engle 2 ปีที่แล้ว +1

    Super well articulated thorough and solid knowledge here. Thank you! 💕

  • @sandrojorgeoliveira175
    @sandrojorgeoliveira175 2 ปีที่แล้ว

    Hi Günther, thank you about this amazing training! The best for you!

  • @clancy-sigal
    @clancy-sigal 2 ปีที่แล้ว +30

    This is an awesome intro on some intermediate git techniques. Looking forward to the Advacned Git tips and tricks!

  • @lsim001
    @lsim001 2 ปีที่แล้ว +11

    Love this talk. Concise but clear explanations on some of the concepts that people misunderstand. Would love to see something similar about the basics e.g. how git work (local vs origin), how commits work etc.

    • @1willFALL
      @1willFALL 2 ปีที่แล้ว

      the intricacies on how commits are created via globs gets very fine detailed, I would recommend reading Pro Git, unless you find some TH-cam video that explains it, please do tell.

  • @javafun
    @javafun 2 ปีที่แล้ว

    I can concentrate well while watch this video, and understood more quickly and deeply, because of your speaking speed that is more comfortable for me. Thanks a lot.

  • @techwithbasil
    @techwithbasil 2 ปีที่แล้ว +1

    Great explanation, precision and clarity on important git concepts. Thank you

  • @p-a5603
    @p-a5603 2 ปีที่แล้ว

    Very good tutorial! Even though I feel quite a familiar with git already, I have learned some new stuff again! :) Btw, very nice solution of solving merge conflicts in Tower! Thanks.

  • @python-programming
    @python-programming 2 ปีที่แล้ว +1

    Looking forward to this!

  • @Metal3z
    @Metal3z 2 ปีที่แล้ว

    amazing work. i finally understood the difference between pr and merge.
    thanks for the amazing explanation.

  • @GhostStyle007
    @GhostStyle007 ปีที่แล้ว +35

    A very important consideration when you start spliting a file into multiple commits is to be very careful about not breaking or creating errors into one of the two generated commits, especially if a CI pipeline is using them.

  • @DavidLindes
    @DavidLindes 2 ปีที่แล้ว

    I'm glad you started with git add -p. I always teach that to folks when I can... it's so useful!

  • @shafayat1004
    @shafayat1004 2 ปีที่แล้ว +7

    This video came just before our first group project for my uni course. Thanks!

  • @giovannichrysostomo2368
    @giovannichrysostomo2368 2 ปีที่แล้ว +7

    First I'd like to thank you FCC and thank all your collaborators that bring content to us! I promise that I'll try to get as much experience as I can to get better and I will retribute all your efforts.
    Regards from Brazil!

  • @iTor
    @iTor 8 หลายเดือนก่อน +7

    I closed my eyes for a moment there and I believe it was truly Christoph Waltz teaching me about Git.

    • @AndrewEsh
      @AndrewEsh 2 หลายเดือนก่อน +2

      I got that too. I was in the bar in Django Unchained, having a beer with Dr. King Schultz, having bounty hunting explained to me.

  • @ahmadjamalmughal47
    @ahmadjamalmughal47 2 ปีที่แล้ว +1

    Man you were so clear and to the point. Thanks for the tutorial it was very informative man.

  • @rishabhjain911
    @rishabhjain911 2 ปีที่แล้ว +1

    I really appreciate this tutorial . It was worth it. Learned something new with excellent explanation

  • @KevenWebb
    @KevenWebb 2 ปีที่แล้ว

    This was very well done. I am sending it on to others. Best video for git at this level that I have seen.

  • @johnbrain3971
    @johnbrain3971 2 ปีที่แล้ว +23

    Very good content, learned a lot through this course, Just a tiny little request: can you please share the slides? So I can make notes more easily.

  • @veziop
    @veziop 2 ปีที่แล้ว

    this is outstanding quality. The pace and the tone might seem irrelevant but they really helps

  • @romanmasiar122
    @romanmasiar122 ปีที่แล้ว

    The way you explain things is simply....awesome. Thanks !!!

  • @user-ho9kr6iw7y
    @user-ho9kr6iw7y ปีที่แล้ว

    Concise explanation, a lot of useful info jammed. Thank you for your excellent work.

  • @tiberio_ck
    @tiberio_ck 2 ปีที่แล้ว

    Thank you so much for this amazing course!

  • @congminhluu5068
    @congminhluu5068 ปีที่แล้ว

    that's such a cool explanation of rebase. The visual helped a lot! Glad I stuck till the end

  • @poischiche2933
    @poischiche2933 2 ปีที่แล้ว

    I'd like to thank you for this video. English is not my native language & I'm a little bit rusty for now, but your spelling is clearly comprehensible. This is great, thanks.
    Besides this, your advice is a pure jewel. Thank you.

  • @joross8
    @joross8 2 ปีที่แล้ว

    Tobias you have a fantastic speaking voice and presentation style. Really enjoyed this practical no bs review of how to use Git effectively,

  • @davidclark1775
    @davidclark1775 2 ปีที่แล้ว +55

    Good content. However, I think you missed one of the more common patterns involving rebase and merge. In your case of an LT branchA and work branchB with changes on both you rebased the changes in branchA on the changes in branchB. In my experience, it is more common to rebase the changes in branchB on the changes in branchA (checkout branchB, rebase branchA, , commit) then merge the resolved changes back into branchA (checkout branchA, merge branchB). That final merge MUST be a fast-forward. If it isn't, start over. This completely avoids the problem of rewriting history on branchA that you alluded to. Given branchA may be used as a base by other developers and could be hosted on a server that disallows history changes, that is essential.

    • @wiurxee1993
      @wiurxee1993 2 ปีที่แล้ว +3

      Also even if you like to rebase an already pushed branch, you could do it safetely using the "git push --force-with-lease" and the "git pull --rebase" options, that will avoid you overwritten any changes made in the remote branch.

    • @markcuello5
      @markcuello5 2 ปีที่แล้ว +1

      What`s a branch?

    • @markcuello5
      @markcuello5 2 ปีที่แล้ว +1

      @@wiurxee1993 What is `Re-base`?

    • @alokbaluni8760
      @alokbaluni8760 ปีที่แล้ว

      @@markcuello5 branch is pointer to the recent commit

    • @hamidr8391
      @hamidr8391 ปีที่แล้ว

      To update a branch we can pull master to that branch :
      Git checkout b1
      Gut pull origin master

  • @adityamishra7486
    @adityamishra7486 ปีที่แล้ว +1

    Awesome tutorial. This man explained everything in a very Calm and awesome way. Loved It!!

  • @zkhan1995
    @zkhan1995 2 ปีที่แล้ว

    a very important video would love to see more like these and some advanced as well!!!

  • @me.shailendra
    @me.shailendra 2 ปีที่แล้ว +1

    Great Job! Now I am confident enough to manage any size code base. Thank You.

  • @ClaudioBOsorio
    @ClaudioBOsorio ปีที่แล้ว

    Man I love these videos. I wish I had the time to watch the whole channel and visit every contributor. Much love

  • @jiren8991
    @jiren8991 2 ปีที่แล้ว +1

    WOW! I was just looking for this. Thanks y'all

  • @nibbanapatipada9538
    @nibbanapatipada9538 2 ปีที่แล้ว +1

    Man! your voice is soo soothing, whenever I get started watching this video, I fall asleep in 5 minutes.

  • @braulioandre2918
    @braulioandre2918 2 ปีที่แล้ว +37

    I've just realized I didn't know Git at all lol. Thank so much for this.

  • @fakedevdutt
    @fakedevdutt 6 หลายเดือนก่อน

    Its been more than 2 years of development i didn't know there was a -p option in add command it could have helped me soo much in past but I am sure it will help me more in future thanks man!!

  • @GarimellaProduction
    @GarimellaProduction 2 หลายเดือนก่อน

    working with git a lot these days and this is great. I have gotten more comfortable with rebase and merge requests

  • @philipoakley5498
    @philipoakley5498 2 ปีที่แล้ว +1

    Good.
    Could be useful to mention where the the merge-base (third source for the merge) comes from.
    Also, maybe worth mentioning on the branching strategies, how it interacts with the team's server fork strategy (or lack of, should it be continuous integrated/merged to the core server approach, e.g. why that rebase warning comment)

  • @TheDorac1
    @TheDorac1 2 ปีที่แล้ว +20

    I was literally looking for these advanced concepts earlier this week! Thank you!

  • @stephane184
    @stephane184 2 ปีที่แล้ว +1

    I’ve been working with GIT for a few years but never got deeper than basic concepts. The patching was neat and will come in handy.

    • @markcuello5
      @markcuello5 2 ปีที่แล้ว

      What is `Patching`?

  • @MrMassaraksh
    @MrMassaraksh ปีที่แล้ว

    I like how you can link commit messages with the tasks, so you don’t need to make them meaningful after this, everything will be in task

  • @itspersie
    @itspersie 2 ปีที่แล้ว +3

    most valuable channel on yt for me rn ✨
    thanks 🤧

  • @jorgewandersantanaurena422
    @jorgewandersantanaurena422 2 ปีที่แล้ว +1

    Thanks.
    It is really helpful to know about git merge/rebase --abort to fast-undo last merge. And good to know about fast-forward, merge-commit & the one done by rebase (I don't know the name)
    I like the tip about commit-message-schema.
    And about branch-strategy, I would prefer short-live branches.
    I love Pull Requests, you can even undo the whole pull request if needed. Even if there are a lot of commits. You only have to revert the pull request. Thats great.

  • @srikrishnanunna1
    @srikrishnanunna1 2 ปีที่แล้ว

    This video is awesome. I derespected Merge vs Rebase ! Thanks again!

  • @rpf23543
    @rpf23543 2 ปีที่แล้ว

    very great tutorial, solved many questions I had, which I never looked up in past...Thank you!

  • @rajat_singla
    @rajat_singla 2 ปีที่แล้ว

    I wish I had such clarity of mind as the person explaining these concepts

  • @chiaramariadedominicis458
    @chiaramariadedominicis458 ปีที่แล้ว

    Maybe the most useful (intermediate/advanced) video on git/Github I've seen so far

  • @abdullahadam7694
    @abdullahadam7694 2 ปีที่แล้ว +3

    Great video! Something which can be useful for finding files with merge conflict markers:
    git diff -check

  • @zucc4764
    @zucc4764 2 ปีที่แล้ว

    One topic in and I knew this is premium stuff. Thank you for this!

  • @savitapandey6604
    @savitapandey6604 2 ปีที่แล้ว +1

    This is the best channel i would suggest every one if they are beginners

  • @voyageruk2002
    @voyageruk2002 2 ปีที่แล้ว

    What a beautifully crafted tutorial.

  • @MrStarcraftangle
    @MrStarcraftangle ปีที่แล้ว

    so SIMPLE explanation of REBASE. Thank you for that 🥰

  • @bharathkumar2007
    @bharathkumar2007 2 ปีที่แล้ว

    Very well explained, short and sweet :)

  •  5 หลายเดือนก่อน +2

    Sometimes it is useful to realize that commits do not carry changes (i.e. diffs), rather they contain snapshots of the whole repository (though unchanged files are reused from previous versions).

  • @kriteshag003
    @kriteshag003 2 ปีที่แล้ว

    Gosh! I needed this. Thank you!

  • @user-gv2cj5so6q
    @user-gv2cj5so6q ปีที่แล้ว +2

    Great video, well explained!

  • @aghaaslam9575
    @aghaaslam9575 ปีที่แล้ว +7

    My Note:
    the arrow of every visualization means the old commit if exist
    Staging is important to differentiate some projects!
    6:17 commit message should have subject and body.
    8:30 conventional branches on team is important!
    IMPORTANT FOR ME:
    24:33 Merge Conflict
    27:55 undo a conflict and start over

  • @hellocheng7071
    @hellocheng7071 2 ปีที่แล้ว

    The video is so clear and helpful , thank you!

  • @betoharres
    @betoharres 2 ปีที่แล้ว +1

    I didn't knew about rebase cons, thanks a lot for sharing this valuable info!

  • @malicianewowlala6655
    @malicianewowlala6655 ปีที่แล้ว

    For sure the best video I watched on git! Thank you so much.

  • @orlandoreyes884
    @orlandoreyes884 2 ปีที่แล้ว +1

    Excellent!! this video has helped me to finally undestand git commands easy explained. Thanks.

  • @rungxanh2901
    @rungxanh2901 2 ปีที่แล้ว

    Thank you Tobias for the wonderful tutorial 💯

  • @MarkBrathwaite
    @MarkBrathwaite 2 ปีที่แล้ว

    Very helpful review of concepts - thank you.

  • @ajjo5513
    @ajjo5513 2 ปีที่แล้ว

    Very informative video. Every thing was very well explained!

  • @ian.c
    @ian.c ปีที่แล้ว

    Love this video especially the pace of the video so much!

  • @MsOfficeLearning
    @MsOfficeLearning 2 ปีที่แล้ว

    Thank for your sharing.

  • @mebasoglu
    @mebasoglu 2 ปีที่แล้ว

    This is video is awesome. Thank you for all the effort. I admire your work.

  • @USONOFAV
    @USONOFAV 2 ปีที่แล้ว +1

    I worked on intellij and I love the merge tool it got. Exactly looked liked the one shown here. My work though still uses eclipse so I might use this git tower app.

  • @chfmrf9605
    @chfmrf9605 หลายเดือนก่อน

    great video, very clear and also with the right amount of valuable background information

  • @flamingwoodz
    @flamingwoodz 2 ปีที่แล้ว

    You are a great teacher!

  • @ricardorosa5315
    @ricardorosa5315 2 ปีที่แล้ว +1

    Real good instructor!! 5 Star*
    Thank you so much!

  • @Bellathor
    @Bellathor ปีที่แล้ว +4

    Fantastic video, nice explanations. Thank you. :)

  • @AshwinPrakashKadayil
    @AshwinPrakashKadayil 3 วันที่ผ่านมา

    Awesome video. Please keep educating us. Thanks

  • @emmy_thoughts
    @emmy_thoughts 2 ปีที่แล้ว +1

    Awesome video.
    Very impactful!

  • @ChanonJ
    @ChanonJ 7 หลายเดือนก่อน

    Great lesson for most of new dev guy who need to use GIT here. Highly recommended :)

  • @marcellinwabo9859
    @marcellinwabo9859 2 ปีที่แล้ว

    Thanks a bunch for this great tutorial. I have just learned many new thing by watching.

  • @shantanushekharsjunerft9783
    @shantanushekharsjunerft9783 2 ปีที่แล้ว

    Found this very helpful!! Are there books or videos on git usages for devops? I have seen devops use more commands than developers to provide good workflows for pipelines.

  • @RashidKhan-vr6rh
    @RashidKhan-vr6rh ปีที่แล้ว

    beautifully explained, really helped. thanks a mil!

  • @mahdiporkar236
    @mahdiporkar236 หลายเดือนก่อน

    Great video. Watched the whole thing and didn't even notice the time.

  • @AnaMaria-ul9qk
    @AnaMaria-ul9qk 2 ปีที่แล้ว

    Thank you!! 🚀💙

  • @atharvaathalye
    @atharvaathalye 2 ปีที่แล้ว +1

    Man. My boss just told me to learn git and then I saw notification for this video.

  • @bitterthread6794
    @bitterthread6794 2 ปีที่แล้ว +1

    The first few lines made me already confident

  • @frazuppi4897
    @frazuppi4897 ปีที่แล้ว +1

    this video is truly amazing, thanks a lot

  • @SLHooLigON
    @SLHooLigON 2 ปีที่แล้ว

    superb explanation. Nice and Clean. thank you

  • @cramhead
    @cramhead ปีที่แล้ว

    I really enjoyed your talk. It really helped in understanding git in a more wholistic manner.