DEV Community

Nina
Nina

Posted on

Is using git without the command line cheating?

I was really scared of git in the beginning. My first instance with it besides being added to a repository I worked as an artist on was with a friend making a game. I now know our issues stem from not using the Unity gitignore settings, but back then it was a mess of commands I didn't understand to try and fix our problems, back when I still thought I was too dumb to code. I thought somehow I had messed everything up, when it just turns out our project settings and libraries were clashing.

Because of this, when I finally started using GitHub I used GitHub desktop, and eventually used the functionality in VS Code. Is this considered "cheating" since I never use a terminal for git, or even know the commands to do so? What am I missing out on when I don't know these things?

Top comments (13)

Collapse
 
ianknighton profile image
Ian Knighton

In my opinion, this is like asking "Is using an IDE cheating".

It's Not!

It's a tool and if it makes it approachable and understandable, then don't be afraid to use it. I've been a developer for a long time, but always used Team Foundation Server. When I started at my current employer, I needed to come up to speed on Git very quickly. Using the GitHub for Desktop application made it so I could learn the things I needed to (node...yuck) without feeling stuck by something ancillary.

Eventually, I did start using the command line, but that was when it made sense to add it into my workflow. Now I can work completely from the terminal, but there are still some tasks I prefer to do through the GUI.

Collapse
 
thermatix profile image
Martin Becker

I have to agree with this, it's just another tool in the box and like almost all tools, there is no better, just better suited. I only advocate going from the command-line because I feel it gives a better understanding of the underlying commands IMHO.
I honestly prefer using sublime merge whenever I have to deal with merge conflicts which just plain suck when trying to do it from the terminal.

Collapse
 
misnina profile image
Nina

Thank you for your opinion, it's good to know it's not completely odd that I started with a tool. Maybe now that I'm more comfortable with it because of GitHub desktop now would be a good time to fill in the gaps with command lines.

Collapse
 
dmfay profile image
Dian Fay • Edited

It's not cheating, but plugins and graphical tools hide a lot of functionality in the interests of making the basic workflows more ergonomic. If you realize you accidentally committed a config with your AWS credentials last week and need to nuke it from every revision it appears in, recover something from the reflog after a hard reset, or do something else outside the day-to-day push/pull, stage/unstage, branch/merge tasks you'll be doing it on the command line. When that day comes (& it is a when) it will be immensely helpful if you already understand what git-the-program is actually doing when you click things in Fancy Git For Them That Like Graphical Interfaces. Don't feel like you have to do everything with typing, but it'd be a good idea to play around with it a bit so you're not starting from zero when you desperately need it.

Collapse
 
pauguillamon profile image
PauGuillamon

Completely agree. I myself have used GUIs for a long time (SourceTree, GitKraken, GitHub Desktop...) and they are very useful for the basic workflow. Unfortunately it is very easy to mess up sometimes with Git, so knowing how it works internally and being able to understand its command line interface will be very helpful.

However Git commands (as a good Linux/Unix command line tool...) are very difficult to understand/memorize. As an example, what does the -d option mean? well, it depends on which command it is applied...

On a daily basis, I would say it's perfectly OK to use GUI clients, especially if they make you more productive! But try to use command line once in a while in order to become more familiar with it, it will help you in the long term.

Collapse
 
misnina profile image
Nina

Thank you for sharing!

When that day comes (& it is a when)

I haven't gotten to that day yet, but you are right, it will come and I'm not sure I'm prepared yet.

Collapse
 
smuschel profile image
smuschel

Don't think you could/should call that cheating. You need to choose the tool that best suits your needs. If you're being productive with a git GUI that's fine.
Of course it's good to know the commands and how Git works in case you need to do stuff on a system without a GUI, but that knowledge may come when you're more familiar with Git...

Collapse
 
thomasrayner profile image
Thomas Rayner

I mostly feel like that using the git cli is the best way to truly u derstand what git is doing. Most of the gui products I've seen are more just for people who wish to memorize what the right buttons are to click that make their code go to origin. If something goes wrong, or anything more complicated needs to happen, it becomes a problem. Obviously a lot of gui tools can handle these situations, but I haven't seen it well organized/represented in guis, and the folks using them don't tend to be ready for it. This is a huge sweeping generalization and clearly isn't always the case. Just my experience.

Collapse
 
misnina profile image
Nina

Thanks for sharing your experience. I can honestly say that I don't know what to do when something goes wrong, so your generalizations might not be too far off.

Collapse
 
jadekin profile image
Karen Pinzás Morrongiello

If it works for you, It is ok!

I usually do that too! I use SourceTree because It is easier for me to check all the branches and do some tasks using the GUI. But, for some other things (like cherry pick), I don't know why I prefer using Terminal. However, for me, It was useful to learn some commands using this interactive tutorial: learngitbranching.js.org. Also, I good way to feel more confortable is to create a private repo and playing around with it :)

Collapse
 
misnina profile image
Nina

Thanks for the link, this tutorial looks great so far!

Collapse
 
samwho profile image
Sam Rose

Not at all! If it works for you, it works for you. 😄

Collapse
 
bradcypert profile image
Brad

Oh, it's definitely not cheating. I use the command line because its faster for me, but I'd definitely use a Git GUI if it felt faster for me.