Git's most perplexing paradigm
5:05
5 (questionably useful) Git tips
8:11
I’m making a big bet…
4:19
11 ай бұрын
My toughest project yet
3:47
Жыл бұрын
Delete Git Commits Tutorial
5:03
Жыл бұрын
Coding ability is overrated
4:24
Жыл бұрын
Git STASH Tutorial
6:59
Жыл бұрын
Resolve Git Stash Merge Conflicts
6:17
Git CHERRY PICK Tutorial
4:42
Жыл бұрын
Basic TMUX tutorial & cheatsheet
4:22
macOS vs Windows for Programming
4:56
My NYC coding setup
4:56
5 жыл бұрын
Пікірлер
@TheRocreex
@TheRocreex 7 сағат бұрын
To clarify a common misconception: A "tree" in the context of Git does not refer to a commit history (because that is not in fact a tree in the mathematical sense due to merges, actually it's a DAG) but it refers to a snapshot of the repo, i.e. the content of a commit and therefore a filesystem tree. That might be important to know so not to get confused when reading the Git docs and learning about the Git working tree.
@user-oj9iz4vb4q
@user-oj9iz4vb4q 16 сағат бұрын
It's simple, never fucking rebase. The very concept of rebasing is fundamentally flawed and only used by damaged OCD people.
@mxsniper223
@mxsniper223 23 сағат бұрын
شكرا جزيلا .. thanks' a lot man
@DavidPashley
@DavidPashley Күн бұрын
I think you may have an incorrect mental model of vim. The escape is not part of the quit command. The default mode in vim is the command mode. i puts you into insert mode and escape leaves insert mode and returns you to command mode. Colon moves you to another mode: ex mode where you can type ex commands. The ex command you're using in this situation is wq. If you're using escape before quitting even when in command mode, then it suggests you're not thinking of insert mode as something you dip in and out of before returning to the steady state of command mode and possibly missing out on the incredible power of command mode.
@themoderncoder
@themoderncoder 21 сағат бұрын
Your comment is a nice, succinct explanation of what I glossed over in the video. It seemed more approachable to gloss over vim modes to make sure folks could save & close a file without knowing which mode they were in. I'll admit my vim knowledge beyond simple commands is limited, I remember first starting out watching senior devs fly through code in vim, and being very jealous. Hopefully one of these days I'll find the time to up my skills!
@DavidPashley
@DavidPashley 21 сағат бұрын
@@themoderncoder Yep, vim is complicated, mostly because it's very different from almost any other editor that just lets you type and go. It's not helped that it's built on top of a very limited editor designed for teletypes (ed and then ex) When I was starting out, I had the same misunderstanding of vi, but someone much smarter than me gently corrected me and I became much more fluent.
@UTube2K6
@UTube2K6 Күн бұрын
9:15
@coreC..
@coreC.. Күн бұрын
This is a clear explanation. Very good.
@sarvanisah2746
@sarvanisah2746 2 күн бұрын
if we are using vi config.yml for vim ide , what command we will use for vs code ide?
@themoderncoder
@themoderncoder Күн бұрын
If you use VS Code you can either open config.yml manually via the file explorer or (if you've configured VS Code to be able to launch from the command line code.visualstudio.com/docs/setup/mac#_launching-from-the-command-line) you could type "code config.yml"
@rezakaaccount
@rezakaaccount 2 күн бұрын
Production quality is remarkable.
@mehdizahedi2810
@mehdizahedi2810 2 күн бұрын
Fantastic explanation, resolved all my confusion about merging. Thanks
@kaibe5241
@kaibe5241 2 күн бұрын
This isn't even close to being definitive... It skips over so many features that git provides for managing conflicts.
@CristianHeredia0
@CristianHeredia0 2 күн бұрын
Great content! What are you using to make slides?
@themoderncoder
@themoderncoder 2 күн бұрын
I use Apple Motion to create the animations. Then stitch all the animations together with Final Cut. It’s a bit of a manual process unfortunately - these videos take me a very very long time to make lol
@davidpaez_co
@davidpaez_co 2 күн бұрын
This is honestly the best git course in all KZfaq. Thank you so much!
@himanshutripathi5735
@himanshutripathi5735 3 күн бұрын
So we merge after rebase? just rebase and push is bad practise? Please clarify. Thanks!
@themoderncoder
@themoderncoder 3 күн бұрын
Generally yes. This video should clear your question up kzfaq.info/get/bejne/sLWeqsqpzqmUf3U.htmlsi=jsqtiCaVkMr2WBLr
@azolee
@azolee 3 күн бұрын
in my almost 15 year of using Git, this is by far the best video on how to use merge and rebase. thank you!
@themoderncoder
@themoderncoder 3 күн бұрын
Really appreciate you saying that. It means a lot coming from someone like you with so much experience. If you have a chance to share this video with someone who might benefit, please do. Cheers!
@azolee
@azolee 3 күн бұрын
@@themoderncoder already did it :)
@edgarlip2
@edgarlip2 4 күн бұрын
very cool , thank you !!!
@davidgood840
@davidgood840 4 күн бұрын
As a single dev , I only ever use rebase amd NEVER merge just to keep the history strictly linear , however this is a luxury that larger teams might not have . The tip about only using rebase for your own local work is 100% the right way to use it , imo .
@daymenpasick7825
@daymenpasick7825 5 күн бұрын
My guy at the very beginning when you described git pull as being a combination of fetch and merge...it already instantly clicked for me xD thank you!
@EzMC2
@EzMC2 5 күн бұрын
Nicely done, thanks my dude.
@yssplays2620
@yssplays2620 6 күн бұрын
new subscriber. best explain very very very nice
@themoderncoder
@themoderncoder 6 күн бұрын
Thank you so much 🙂
@SalvadorAguilar
@SalvadorAguilar 9 күн бұрын
Thank you a lot for this brother!
@themoderncoder
@themoderncoder 9 күн бұрын
For sure, glad it was helpful. If you know anyone else who would benefit, please share a link!
@tarsala1995
@tarsala1995 11 күн бұрын
I always squash and never allow teammates to work on my branch. This way you maintain main branch clean with only feature commits and avoid conflicts with teammate locally. The only use case I had was when I was introducing a big feature >100 files and split my PR into 6, then I was rebasing branches in order of building block of the feature, where last branch was rebased into main feature branch after reviews of my peers.
@themoderncoder
@themoderncoder 11 күн бұрын
This a good anecdote for folks - in the real world sharing branches is not very common and workflows like you describe are more the norm.
@jojje3000-1
@jojje3000-1 12 күн бұрын
Git mergetool is also useful
@ekchills6948
@ekchills6948 12 күн бұрын
Best explanation
@fouadchahd2969
@fouadchahd2969 12 күн бұрын
Please can u provide commads also
@themoderncoder
@themoderncoder 11 күн бұрын
This is the video you’re looking for: Git MERGE vs REBASE: The Definitive Guide kzfaq.info/get/bejne/sLWeqsqpzqmUf3U.html
@RakeshKumar-tu6bi
@RakeshKumar-tu6bi 13 күн бұрын
perfect
@porchmail
@porchmail 15 күн бұрын
Truly appreciate! This is one of the best IT tutorial videos that I’ve ever seen!
@subramanyakrishnamurthy8352
@subramanyakrishnamurthy8352 15 күн бұрын
"No nonsense, just get to the point" videos. Very easy to follow and much appreciated!!
@chrism9017
@chrism9017 15 күн бұрын
1:00-1:05 "... my local main branch hasn't changed". Light bulb on.
@nipping1212
@nipping1212 16 күн бұрын
Great video :)
@EricMuranoAU
@EricMuranoAU 16 күн бұрын
If you push your feature branch to remote, but no one touches your branch, is rebase still safe?
@themoderncoder
@themoderncoder 16 күн бұрын
Yeah, rebase should be pretty safe in that scenario.
@shoooozzzz
@shoooozzzz 16 күн бұрын
thank you for a true lightbulb moment! It just makes sense now
@shoooozzzz
@shoooozzzz 16 күн бұрын
You are the git goat with your visualizations.
@CentreMetre
@CentreMetre 16 күн бұрын
I first seen your merge vs rebase a couple days ago and it really helped explain. KZfaq seemed to agree and recommended me this straight after uploading (im not subscribed), and again really helpful video. Gonna have to check out more!
@themoderncoder
@themoderncoder 16 күн бұрын
Good to hear. These videos end up taking way longer than I think to film and animate, so it really makes me feel like it’s worth it when I get comments like yours.
@shoooozzzz
@shoooozzzz 16 күн бұрын
@@themoderncoder the time spent is worth it. You are creating a better world for software devs
@hrahman3123
@hrahman3123 16 күн бұрын
You always have great videos. Keep it up!
@devcallum
@devcallum 16 күн бұрын
Not first but second
@themoderncoder
@themoderncoder 16 күн бұрын
Let’s go! I never get “first” or “second” comments on my vids!!
@linbynd
@linbynd 16 күн бұрын
perfect !!!
@user-lk1md5mn1i
@user-lk1md5mn1i 18 күн бұрын
not useful
@alenscaria1516
@alenscaria1516 20 күн бұрын
Syncing repos was a nightmare for me. Not anymore! Thanks A lot!!!
@user-eq4zl8mq7k
@user-eq4zl8mq7k 20 күн бұрын
thank you so much. this has been the clearest explanation I`ve encountered. I have a test soon about this topic, and also need it currently for another school project :)) but solving the conflict on the terminal always seemed so intimidating
@siddharthnayak4448
@siddharthnayak4448 21 күн бұрын
I had faced an issue while uptaking merge branch additional commits into feature branch using git merge in gitlab UI where merge conflict was arising. When I resolved then conflict on gitlab UI itself and merge request was granted, both the main and feature branches got merged into each other and main branch had the commits of feature branch😠. Any reason for this weird behaviour?
@Brxndz_
@Brxndz_ 21 күн бұрын
This was awesome! Online can make rebase look so terrifying
@AkimboFennec
@AkimboFennec 22 күн бұрын
I read the official pro git textbook, but did not understand what i should have done with the conflict. Then i searched for git merge conflict and found your KZfaq channel. Thank you for this video. The only recommendation is to speak a little bit slower, to give us time to digest the information. Other than that I really loved the combination of an animated graph, which underpins the theory, and a practical conflict resolution using a manual process, or VScode. Again thank you. By the way i will checkout the website and purchase the git course.
@themoderncoder
@themoderncoder 21 күн бұрын
Appreciate that! Definitely check out the course. Pacing is not the only reason, but I feel more comfortable taking my time and going really deep in the LearnGit.io lessons. YT seems to favor those shorter, punchier style videos (and I agree) they’re not always the right fit, especially for the more complicated Git concepts.
@mariocalderon2148
@mariocalderon2148 23 күн бұрын
Thank you, amazing! I was always "afraid" of using cherry picking, but with this excellent explanation I will use it often.
@Confusedcapybara8772
@Confusedcapybara8772 23 күн бұрын
Great video. Would love to see how this plays with pull requests
@themoderncoder
@themoderncoder 23 күн бұрын
True. My next few videos will be on Git collaboration and I think PRs could fit nicely into that series
@kirank3368
@kirank3368 23 күн бұрын
This is insane ❤
@joaomendoncayt
@joaomendoncayt 25 күн бұрын
Amazing video.. Was struggling a bit with conflicts and the log and decided to dedicate an hour for a couple videos to once and for all kill all the missing pieces in my mental model even though I use git for years... One thing that wasn't 100% clear is at the end of the video the "recommended workflow" tells you to rebase your branch and then merge it when ready, but that doesn't apply if the branch is on remote and has more people working on it correct? That would mean that remote branches should never get the latest changes from their parent branch unless absolutely necessary, and in that case you'd need to merge from the parent branch.
@themoderncoder
@themoderncoder 23 күн бұрын
Right, that would necessarily apply if multiple people are working on the same remote branch. Like you said though, in those cases you can merge main INTO the remote branch - you’ll just end up with a merge commit which isn’t too bad.
@mariocalderon2148
@mariocalderon2148 26 күн бұрын
Thanks a lot! At last after several years using Git, I (think) I finally grasped it.
@celikvolkan
@celikvolkan 26 күн бұрын
Best explanation I have ever seen on KZfaq about merge vs rebase. Thank you for sharing.😺
@budivoogt491
@budivoogt491 26 күн бұрын
Great video, thanks for the effort.
@abcdabcd8605
@abcdabcd8605 27 күн бұрын
Amazing explanation. Those animations made it very easy to understand.