DEV Community

Cover image for Improve your productivity by using more terminal and less mouse (🚀).
Sotiris Kourouklis
Sotiris Kourouklis

Posted on • Edited on • Originally published at sotergreco.com

Improve your productivity by using more terminal and less mouse (🚀).

Many beginners might think that only senior developers can use the terminal for productivity. When I started learning programming, I was afraid to use the terminal for anything beyond basic tasks like npm commands.

However, over the years, I realized that I missed a huge opportunity to enhance my productivity. So, we are going to explore all the reasons why you should use the terminal more and some tools that can help you become more productive.

Also let's be honest to all the mouse-only-users you are kind of dull.

The mouse is slow 🐌

Basically, the less you use the mouse, the faster you will be. Keeping your hands on the keyboard will save you a ton of time. And let's be honest, if you are using the mouse for most of your activities, you are kind of noob.

Navigating folders

Who the hell uses the file explorer on their computer? I mean, even if you are a Windows user, the file explorer is basically shit, but even on Mac, using the terminal to navigate is much faster. For the people that are using file explorer on Linux, I hope God forgives you for your sins.

Create files and directories

The people who right-click to create a file are said to have mental issues, although I don't completely agree with that, I am 82% there. Commands like touch , mkdir and ls are basically lifesavers when it comes to productivity.

Using cat to quickly peek through a file is also very helpful.

And I want to hear your opinion on that in the comments. What other commands are you using?

What if I am on Windows?

First of all, if you are a Windows user, your situation might be worse than those who use right-click to create a file. However, this is a discussion for another day.

By installing Git Bash, you will basically have almost all of the Unix system terminal commands and move away from the PowerShell disease.

windows = 🥲

Nano or Vim

Understanding the basics of nano or vim will prevent you from opening slower alternatives like vscode or jetbrains. When you want to quickly edit a small file, opening an IDE or Text Editor just to change a few lines of code can be a betrayal to the developer community.

Also, that means you are basically useless when it comes to servers.

ZSH

If you are not using oh-my-zsh, you are missing out on some amazing plugins. One feature most people wish the terminal had is autocompletion. With the zsh-autosuggestions plugin, your terminal will autocomplete most commands and remember previous ones.

So, for all the up-arrow 🔼 fighters out there, you will stop pressing the up-arrow key 500 times to find one old command because you are tired of googling.

Hardcore Stuff (🍆)

Switching to neovim with tmux makes you look like some kind of a porn-star coder. You will appear cool in meetings and when you share your screen to show your code.

Besides the funny side of things, if you are willing to switch to tmux with neovim, it can make you a 10X developer. I could extend and talk for hours on how beneficial it can be after you go through the learning curve, but that is an article of its own.

Conclusion

So, there you have it! Ditching the mouse and opting for the command-line is like upgrading from a bicycle to a rocket ship—it's faster, cooler, and the view is spectacular!

By getting cozy with the terminal, you're not just speeding up your workflow, you're also joining the leagues of elite developers who can make magic happen with a few keystrokes.

Remember, every master was once a disaster.

Thanks for reading, and I hope you found this article helpful. If you have any questions, feel free to email me at kourouklis@pm.me, and I will respond.

You can also keep up with my latest updates by checking out my X here: x.com/sotergreco

Top comments (27)

Collapse
 
latobibor profile image
András Tóth • Edited

Hey, senior software engineer here. I try to use a great IDE as much as possible and the terminal as little as possible.

Why? Let's say I'm writing and fixing unit tests. The jest integration runs in my Webstorm works as a breeze: I get diff, I can click on the failing test, it jumps to the relevant line in the codebase, I can put in a breakpoint if I want it and so on. Lightning fast, I have everything at my hands, no need to manually scroll, load, struggle with something. 21st century experience.

I do advocate for learning the keyboard shortcuts while using the IDE and also to learn tricks like multiline cursor editing and so on, because they save so much time.

Now, about typing speed. Mostly I think for a while, then type out my code, the check the results (either through a unit test or on the frontend). Half of my "coding time" is actually also talking with stakeholders, making agreement with my colleagues on what to work on and what not to work on. It's not a typing competition, it's not a copy-paste-modify extravaganza. If I'm writing 2-3x times the same thing or modified version of the same thing I step back to evaluate if I need to extract the code or if I expect them to diverge a couple of iterations later, therefore no need to extract the code. It requires stopping and thinking, nonetheless.

Finally, about CLIs: I hate command line interfaces. They violate "avoid mental mapping" principle of clean coding: you have to memorize the flags for each CLI tool, remember if -f was file or force or folder or something completely different. There are conventions, yes, but not everyone follows them. The only things I do in the terminal are basically "npm start" or "npx something something". Very, very limited instructions.

Summary: you have to use the tools to be productive. You have to code and plan your productivity in accordance of the tools available. If you "muscle" your code through and ignore very effective coding assistance tools, you can have the illusion of productivity as you type a lot, and press Enter a lot, but in reality you are doing double/triple work.

Collapse
 
nandorholozsnyak profile image
Nándor Holozsnyák

Exactly 👆
I share the same opinions, although I still want to learn how to use Neovim and standard vim. 😅

Collapse
 
latobibor profile image
András Tóth

Thanks for your comment and for all the likes on it! Sometimes I feel alone with my opinion and that's pretty scary. So your support feels encouraging.

Collapse
 
csuriel profile image
Crhistopher Suriel

💯💯 I couldn't agree more.
Also, appearing cool just because of my console appearance is not one of my goals 🚶🏻‍♂️‍➡️.

Collapse
 
latobibor profile image
András Tóth

I have a feeling that other things can be also at play:

  • influenced by a famous engineer who uses terminal for everything
  • a bit of impostor syndrome: the Big Fish uses terminal and VIM therefore if I don't they will think I'm just an impostor
  • neurodivergency 1: some people have very low tolerance to any type of slowness, they prefer high responsivity - IDEs, since they provide many functions tend to have problems with that time-to-time
  • neurodivergency 2: some people have excellent mental mapping abilities (thinking of my university math teachers) who tend to prefer tools with hardcore mental mapping; since it's a "superability", not the norm, I would not force it on others, personally (I don't have it - I love clean code for this reason)
  • freaking out grandma that you speak directly with the CPU if you use those tools
Collapse
 
phalkmin profile image
Paulo Henrique

terminal is 🔥 - I dare any GUI to let me type fuck and then get the correct command I need.

( But I still need to make zsh better on mac - AND discover how to make the settings work when I'm connected via ssh)

Collapse
 
secondsleepblaine profile image
Blaine

I agree with the overall thesis here. One thing I'd add is that if you're a beginner, you may need to force yourself to use each CLI tool even though it will be slower at first. But if you eat your vegetables for just a few days, you'll be rewarded.

The whole Windows vs Mac argument is silly, silly, silly. We love to act like there's an objectively better OS, but it's all just opinions. I'm a Mac user who works heavily in the Microsoft ecosystem and I love it. I also think Windows is amazing OS. I also think the Ubuntu desktop is fantastic.

However, I can objectively say that PowerShell is superior to all CLI options. Come on, it's an object-oriented shell that runs on all platforms! If you disagree, you're an idiot.

Collapse
 
ruanltbg profile image
Ruan Carlos

Hey you, if you are a new engineer around, don't fall to this post.

  • The guy that wrote this is not a senior engineer, he has only 7 years of experience.
  • The text is based on his opinion not based on data.
  • The text has no fundaments, as if you as engineers spend most of your time creating folders or touching files. If you do that or use that as param to compare productivity, you are for sure not a senior+ engineer.
  • What is productivity and why create a folder 0.01 second faster matters so much for you to be disrespectful to others?

Kids, don't be like this person, be respectful, add your opinion not impose it.
Gather data, measure, compare and then expose the result. Have a positive thinking and try to aggregate.

This post is so disrespectful on so many ways that deserves a report.

Collapse
 
purdy profile image
Jason Purdy

When it comes to trying to find a previous command in your terminal, you can use Ctrl+R and it pulls up a search where you can type part of the command to find it. You can hit Ctrl+R repeatedly to go through other results. Bonus, this feature is also available in your MySQL/MariaDB console.

Collapse
 
orenc profile image
Chanan Oren

Also, as long as you have "stty -ixon" (Linux and *BSD I'm not sure about MacOS) in the shell session (in config or manually run), if you Ctrl+r past your intended command you can switch direction and search forward with Ctrl+s (if you don't turn off the flow control commands with the above stty command then when you press Ctrl+s the shell output will appear frozen until pressing Ctrl+q)

On ZSH with flow control commands disabled then Ctrl+q is mapped to push-line by default you can remap to push-line-or-edit (sgeb.io/posts/bash-zsh-half-typed-... )

Collapse
 
marissab profile image
Marissa B

I get where you're coming from, but gatekeeping, nasty stuff like this:

Also let's be honest to all the mouse-only-users you are kind of dull.
if you are using the mouse for most of your activities, you are kind of noob.
The people who right-click to create a file are said to have mental issues

...just makes you come off like an unprofessional jerk, which I don't think was your goal here and it's not the kind of vibe this site is about.

Collapse
 
ezpieco profile image
Ezpie

NeoVim Mentioned! Let's go!!!!

Collapse
 
ezekiel_77 profile image
Ezekiel

Powershell Alternative for touch is New-Item or ni. And No Powershell is not shit

Collapse
 
orenc profile image
Chanan Oren

Does New-Item also update the timestamp on existing files? I'm not against PowerShell, just might not be an entirely equivalent command if it doesn't update timestamps (though does cover the most common use).

touch updates accessed and modified timestamps if the file(s) exist (current time by default arguments available for setting a specific time).

Collapse
 
jefflindholm profile image
Jeff Lindholm

Nope it does not - but it is easy to create a touch command in powershell, and put it in your profile.

Collapse
 
gokayburuc profile image
gokayburuc.dev

I also recommend adding key assignments and job automation and specifying time differences.

Especially for very repetitive vim regex or file searches opts, assigning keys provides a tremendous speed increase in tasks.

Collapse
 
citrix123 profile image
RahulAN

Hello there, I like your post, but I would recommend to make a combination of Windows and Linux. Development on Linux is much better it depends on your domain, I mostly spend my time with remote ssh Linux workspace on vscode on Windows, It makes debugging much much easier than vim where you have no X environment running at all.