DEV Community

Cover image for 15 Command-Line Tools to Make You Better at Shell & CLI
Zaiste
Zaiste

Posted on • Originally published at zaiste.net

15 Command-Line Tools to Make You Better at Shell & CLI

Shell is the essential tool for every programmer. The more familiar you become with the available tools, the more efficient you can be with using your computer. Here's a list of command-line tools that aim to provide modern, often much faster, alternatives to the existing shell commands. These tools will boost your skill at shell.

bat

bat is a cat clone with syntax highlighting and Git integration that works on Windows, MacOS and Linux. It provides syntax highlighting for many file extensions by default.

bat

GitHub

exa

exa is a modern replacement for ls, the default command-line program in Unix/Linux for listing directory contents. exa supports icons with the --icons flag.

Alt Text

GitHub

fd

fd is a fast and user-friendly alternative to find, the built-in command-line program in Unix/Linux for walking a file hierarchy. fd provides opinionated defaults for the most common use cases. To find a specific file by name, you write fd PATTERN instead of find -iname ‘*PATTERN*’. fd is also extremely fast and it comes with a ton of options like ignoring hidden directories, files and patterns from .gitignore by default.

Alt Text

GitHub

procs

procs is a modern replacement for ps, the default command-line program in Unix/Linux for getting information about processes. It provides convenient, human-readable (and colored) output format by default.

Alt Text

GitHub

sd

sd is an intuitive find & replace command-line tool, it is an alternative to sed, the built-in command-line program in Unix/Linux for parsing and transforming text. sd has simpler syntax for replacing all occurrences and it uses the convenient regex syntax that you already know from JavaScript and Python. sd is also 2x-11x faster than sed.

sed is a programmable text editor, with search and replace being a common use case. In that light, sd is more like tr, but on steroids. (thanks /u/oleid for the suggestion).

Alt Text

GitHub

dust

dust is a more intuitive version of du, the built-in command-line program in Unix/Linux for displaying disk usage statistics. By default dust sorts the directories by size.

Alt Text

GitHub

starship

The minimal, blazing-fast, and infinitely customizable prompt for any shell.

Website

ripgrep

ripgrep is an extremely fast alternative to grep, the built-in command-line program in Unix/Linux for searching files by pattern. ripgrep is a line-oriented search tool that recursively searches your current directory for a regex pattern. By default, ripgrep respects .gitignore and automatically skips hidden files, directories and binary files.

Alt Text

GitHub

tokei

tokei is a program that displays statistics about your code. It shows the number of files, total lines within those files and code, comments, and blanks grouped by language.

Alt Text

GitHub

hyperfine

hyperfine is a command-line benchmarking tool. Among many features, it provides statistical analysis across multiple runs, support for arbitrary shell commands, constant feedback about the benchmark progress and current estimates and more.

Alt Text

GitHub

ytop

ytop is an alternative to top, the built-in command-line program in Unix/Linux for displaying information about processes.

Alt Text

GitHub

tealdeer

tealdeer is a very fast implementation of tldr, a command-line program for displaying simplified, example based and community-driven man pages.

Alt Text

GitHub

bandwhich

bandwhich is a CLI utility for displaying current network utilization by process, connection and remote IP or hostname.

Alt Text

GitHub

grex

grex is a command-line tool and library for generating regular expressions from user-provided test cases.

Alt Text

GitHub

zoxide

zoxide is a blazing fast autojumper, intended to completely replace the cd command. It allows you to change directories without typing out the entire path name.

Alt Text

GitHub

Bonus: nushell

nushell is a new type of shell, written in Rust. Its goal is to create a modern shell alternative that's still based on the Unix philosophy, but adapted to the current era. It supports piping and filtering in a way similar to awk and sed with a column view so that you can combine operations like in SQL. (thanks /u/matu3ba for the suggestion).

Alt Text

GitHub

Have I missed an interesting command-line tool? Let me know on Twitter.

Oldest comments (18)

Collapse
 
darkwiiplayer profile image
𒎏Wii 🏳️‍⚧️

More than make you better, it seems these tools will just make your life easier. Also, why is thefuck not on the list? :D

Collapse
 
nishithsavla profile image
Nishith Savla

Just checkout it out!!! How thefuck can it be so amazing...😁

Collapse
 
phantas0s profile image
Matthieu Cneude • Edited

These tools display more colors indeed.

They don't make you better, but they are useful.

We should keep in mind that most tools used out there in scripts are the one created decades ago.

Collapse
 
imowbray97 profile image
Isaiah Mowbray

Very true!!

Collapse
 
omulmicsinegru profile image
Ionita Matei Iosif

This is an awesome list !

Collapse
 
fennecdjay profile image
Jérémie Astor

Nice article!
I already switched to bat and ripgrep, but I just added fd and procs as alias to my zshrc.
Not so sure about about sd or exa, as I use lsd and like sed as is.
grex seems very nice, I don't know if I have a use case for it.

I think you should provide links to those programs, that's the only thing you missed.

Collapse
 
bhagatparwinder profile image
Parwinder 👨🏻‍💻

Great job @zaiste ! The list is excellent and much appreciated.

Collapse
 
madza profile image
Madza

could you please share your cli configuration? 🙂
that font and theme looks super clean ❤ 👍

Collapse
 
alessandrolia profile image
alessandrolia

Great list!!!

Collapse
 
cromatikap profile image
cromatikap

Awesome tools!

Collapse
 
mstryoda profile image
Emre Savcı

Awesome tools, thank you for that. I can suggest another which name is docker-shell to the list. It is a command line prompt for docker, with command & port suggestions with image search capability.

github.com/Trendyol/docker-shell

Collapse
 
vlasales profile image
Vlastimil Pospichal

I was not interested in this list of tools, but I respect it.

Collapse
 
ricardokl profile image
ricardokl

I’ll try some of these!
I have also hear of bashtop and seems nice
These days I navigate directories with fzf

Collapse
 
andrewbaisden profile image
Andrew Baisden

Good list of tools!

Collapse
 
yofriadi profile image
yofri

I use sheldon for managing my shell plugin github.com/rossmacarthur/sheldon

Collapse
 
jaw profile image
James

I had a few of these already, so was interested by other alternatives (like procs, which is great), but initially didn't bother with tealdeer because "tldr is fine". Just gave it a go and let out an audible "oh" because it's so much faster. Thanks for the article!

Collapse
 
supersandro2000 profile image
Sandro

Great list but the link to bandwhich is missing.

Some comments may only be visible to logged-in visitors. Sign in to view all comments.