Why Learning the Command Line is Critical

It’s can be deemed the most useful and necessary tool out there for any developer, yet for green engineers, it can an anxiety inducing. I’m talking about the command line, aka terminal, shell, command prompt, etc… While it’s not some fancy UI tool, it is a something I can (nearly) guarantee you’ll use in your career.

My first class, years and years ago, in computer science was Linux 101. A good chunk of the class was focused on interacting with the Linux kernel through the command line. Of course, at the time I asked myself “I’ve got FileZilla to move items around, why would I use the command line? ” Quickly I learned though that’s its functionality is more than meets the eye. It is a shell that can control very complex operations within your system, that other areas cannot.

As a software engineer, I use the command line daily. It’s quick and efficient. It uses much less CPU time as other interfaces. I’m not doing anything too complex, but it sure makes things easier once you know the commands to use! For example, I want to securely copy a .tar file from my local computer to a different system on my network. Sure, I can open up FileZilla, ssh into the other computer, make sure my credentials work, wait for it to load, find my local file and drag and drop it on the remote computer. Or I can run a “scp <filename> <target_computer> command from terminal, and it transfers that .tar file quickly and easily.

Sometimes, it can help when trying to get access to a remote computer. Just the other day, I was using VSCode’s Remote Explorer extension to SSH into a server. It kept giving me an access error and I couldn’t figure it out. After about ten minutes, I gave up and just used the command line “ssh <username>@<server_name)” and just like that I was in. It took less than 30 seconds.

The advantages go on. It’s easy to handle repetitive tasks one after the other. It uses less memory. It doesn’t require Windows or a Mac OS. You can do most anything from it with fewer resources!

Need to edit one line in a file you’ve already transferred to a remote computer? Use vi(m) through the command line! I read an article the other day comparing editors. Vim uses one process, 2.4MB and one thread, while VSCode uses six processes, 356.3MB and 134 threads. You can see that using vim saves bunch of processing time and space.

Let’s not forget, many cloud services are operated through the command line. Most projects that require an immense amount of computing resources are run through the cloud, and interaction with those services are through command line interfaces.

There’s plenty of reasons why learning the command line is important for any engineer. You can develop faster. It is very intimidating at first, but after a while you’ll find it’s much simpler. You enter a command. It either does what you want or it tells you what’s wrong. Plain and simple.

Print Friendly, PDF & Email

One thought on “Why Learning the Command Line is Critical

  1. Good read. I know there are plenty of resources out there to learn the command line and there are plenty of other subjects to cram into a limited number of classes, but I wish OSU focused on it more in some of their CS classes. Other than 344 and small sections of 290 and 362, there is not much time dedicated to it.

Leave a Reply

Your email address will not be published. Required fields are marked *