In every post which is about git on HN, there are a lot of people complaining how unintuitive it is with this being the latest one.
However, I am not sure if this is just a symptom of people not caring enough to learn the tools they use every day; if I just have bad memory about my own time learning git or if I just had more time than others to care about stuff like this.
I kind of feel similar to this commenter:
I have contradictory feelings regarding git. For more than ten years, I was using it daily without really understanding the internals... and I was often confused and frustrated. After investing some time learning how the Directed Acyclic Graph works, suddenly everything made much more sense. And, yes: it is good to learn the underlying fundamentals of the technology we are using. But, on the other hand, it denotes a rather poor abstraction from the UX point of view, imho.
Now, when I deliver git training, I start by explaining the DAG and how there is no magic, only git. By the way, the notes and exercises of the course are in my GitHub account[1], feel free to check it out if you think it can be useful.
What about you?
Knowing git is the difference between a developer and a script kiddie. I say this from personal experience. Doesn't have to be git, it's just the only source control on familiar with.
reply
git is the difference between a developer and a script kiddie
git, it's just the only source control on familiar with
Yeah, maybe slow down a little bit here. These technologies come and go. Git is literally only 15 years old. A lot of the tech you use every day was and is developed with e.g. SVN. Some of the most hardcore tech dudes I know are 50+ years old, are real veterans in in broad variety of technologies, have extensive knowledge on a lot of low-stack tech and only recently learned adopted Git.
Or to say it more provocatively: If you only know Git, you're still a kiddie. Good developers are tech-agnostic, don't define themselves by the tech they happened to be born in and can adapt to the current state of technological advancement
reply
Linux is only about 30 years old, is it a fad like Git?
I disagree with what you are saying, Git was created by Linus Torvalds because there wasn't a tool that was good enough. Git worked, it overtook all other SCMs, because it's better. I don't see a big downside in learning other SCMs, but git is better then them by miles. If someone with 50+ years in the tech world said they were better at writing software than Linus Torvalds I'd ask for receipts. Didn't they create not 1 but 2 tools that are kicking ass?
reply
We use it for everything. In terms of server instances, we also run gitlab and gitea, slowly moving away from the dreaded (microsoft) github.
reply
Amen to that, not your git not your app, and microsoft owns it (or part of it) if you still on github. GitLab has community addition, "self custody your code" You will live longer..lol
reply
I agree with that. I don't use Github for my personal projects anymore. Currently, I use Gitlab for "bigger" projects and gitolite for smaller and private projects.
But I want to migrate to fully self-hosted for all my repositories but don't want to use gitolite anymore (had some problems with it regarding creating new repositories and general administration). I am thinking about migrating to soft-serve or Gitea.
reply
I would suggest CE gitlab if you don't mind doing some sysadmin work. If you managed jenkins server or any image repo (nexus, artifactory) it would be a breeze. You can get your own domain (e.g. gitlab.ekzyis.com) and full unrestricted features of gitlab.com. It's work, but all worth it in my humble opinion. To each his own tho...
reply
I've heard Gitlab is quite demanding on resources. I only have 2GB RAM on my VPS and I would probably only want to use 10-25% of that for git hosting.
Do you think that's enough for CE Gitlab?
reply
2gb is not enough for gitlab
gitea is much more memory efficient
reply
Naa man. You really need a decent server. I run on 12GB of ram and even that swaps sometimes and it ain't even busy. It runs a lot of auxiliary services and I run some additional security tools. VPS will cost you a pretty penny and I wouldn't recommend that. CE gitlab is really designed for good internet connection (fiber at home?) and a decent server that you control 100%, so solid homelab is a perfect candidate for it. Basically the more RAM you can afford the better, also OS helps, for example Debian runs a lot of less "crap" than Ubuntu, so pick your poison... hope this helps.
reply
I am so used to git now that doing without got would be like being told to work without my arms. But I agree at first we have to learn. I used classes for that in the past, it was helpful.
I use git only in a basic way though (save patches, apply them, rebase, merge, pull, push, change the origin, save the stash, etc). In the past I have learned ways to display the state of a branch in a fancy way for example, but never used it much besides for learning.
My usage may be so basic that I never got frustrated to empathize but for me the only pain in the ass I have is in a team work to merge and rebase sometimes when we edit the same file and I don't know why there was a specific change. In this kind case I just ask (which is rare).
reply
git is nice, it basically allowed massive collaboration in the last decade or so through github in particular.
Decentralized source control like git is better than centralized, like svn for example, even though svn and similar seem easier to use in the beginning.
reply
Git isn't perfect. It also isn't that hard to learn for a developer. I will say I have even seen brand new devs pick it up pretty quickly. I'm not saying this to say it can't be improved or there isn't a better tool but I have yet to see another tool to rival it.
If you write code and don't use Git you are really missing out. Its a powerful tool. I like to explain to folks like this. Git is a set of good steak knives. They are sharp so you need to learn or you could cut yourself. I'd rather have a set of sharp knives than dull ones. Dull ones are often even more dangerous.
Git was built to be decrentralized but people focus their work around Github for convenience. Then with Github has an issue devs can't get work done... Remind you of anything?
reply
Git isn't very hard. The people who never learn it probably just aren't being forced to use it, or at least use it properly. A lot of people don't know how useful using git properly can be because they're never shown. All they use it for is prs with their hundreds of commits and merges
reply
The abstractions could be better, but it's a lot like bitcoin in that its fundamental nature is pretty much irreducible given the requirements its designed to meet.
I understand git probably better than most people but I still mess up a lot of the time because I haven't spent enough time learning how to communicate with the merkle DAG.
I found this book really helpful if anyone is looking to go deep on git: https://git-scm.com/book/en/v2
reply
A few weeks ago, I used the command
$ git rebase --onto master local-dev <feature-branch>
for the first time and I felt like I ascended, lol
I used it to no longer keep untracked changes in my local repository (changes in .next.config.js and .env.sample). I created a local-dev branch and then create branches from that one.
And before I push, I run this command so my local changes are no longer included in the branch.
Basically, it goes from this:
A---B---C---F---G (master branch) \ D---E---H---I (feature-branch) ^ (local-dev branch)
to this
A---B---C---F---G (master branch) \ \ \ E'---H'---I' (feature-branch) \ D ^ (local-dev branch)
reply
I have done this once but this is seriously bad ass. This is a great usage of this command!
reply
Magic
reply
I did not git it(😉) when I first learned in school. The basics were fine, but as soon as I worked with a team and had merge conflicts, boy was that awful.
I took the time to study it more, and now that I use it professionally, I find it very easy to use, though I still look things up from time to time.
It's an amazing tool that solves a lot of problems, while not being the easiest to learn.
reply
I think it’s a super super powerful tool that I will never fully understand and a tool which gives me superpowers the more I learn about it.
Nowadays we have AI and I’m constantly using it to unlock git’s potential.
reply
In my career I've used git, mercurial, subversion, clearcase and cvs. git is much better than all the rest for all kinds of reasons. I'm very happy with it. Occasionally do something complicated but most of the time just doing the same ol' same ol' vanilla version control and it's ace.
reply
I am always scared when merging different branches. It feels like I am not in control and that something is going to be wrong, but then it works 😃
reply
Gitlab/Github etc do a great job at doing merge requests. You'll see what the result would be without
I remember the feeling man. Messing up a merge and undoing instead of pushing is an eye-roller. A good workflow with code reviews and merge requests and this will be a non-issue
reply
I have my own aliases for most of common git commands and combos. That solved it for me.
reply
git is a version control system nothing else nothing more, use it as a tool. Maybe not perfect but its the best tool we have. Learn it and use it, can't live without it in today's world of "deploy everything now" ... Stop listening to people's bitching and do your own thing.... and stack sats... :-)
reply
learn git learn vi(m) self custody bitcoin run your own node use nostr
reply
It was hard for me to learn, and I still can't say I understand it that well, only well enough to use it in a fairly basic way.
But, even with the little I know, I find it an indispensable tool and crucial for any complex project
reply
I can't live without git anymore. Anything I do must be version controlled now.
Else I feel like I am one step away from losing all my progress, lol
reply
What's wrong with Report.doc.final.v1.102.use_this_one?
reply
git is like "save every 10 minutes, using a different save slot" for video games
reply
I can't live without it now, but has been something not easy to learn for me.
reply
I think it has alot of potential. I see there can be some improvements in the flow of things. They should have a mechanism to prevent some mistakes, have less commands to do certain task, and make it more user friendly. It also be nice too if they can rebuild the tool using Rust or Zig language.
reply
Git is a free and open source distributed version control system designed to handle everything from small to very large projects with speed and efficiency.
Git is easy to learn and has a tiny footprint with lightning fast performance. It outclasses SCM tools like Subversion, CVS, Perforce, and ClearCase with features like cheap local branching, convenient staging areas, and multiple workflows.
reply
A great VCS for building software with teams & members spread all across the globe!