/ factorpad.com / tech / linux-essentials / whatis-command.html
An ad-free and cookie-free website.
Beginner
Learn to find quick summaries of commands at the Linux command line.
Videos can also be accessed from the Linux Essentials Playlist on YouTube.
Linux whatis command summary with examples (3:35)
Our second word, or command to memorize is whatis
from the category Help.
whatis
allows you to display one-line
manual page descriptions. We will cover user manual pages, but just so
you know whatis pulls the shortest description from those pages.
-options | description |
---|---|
-h or --help |
Print help screen |
--usage |
Print usage syntax |
If it helps, think of commands as mini programs and most have this
structure. First, type the
command
, second the
-option(s)
and third the
argument(s)
.
The whatis
command has
13 options and the argument is typically another
command. It is lowercase whatis
followed by one or several optional options, then the command name
and Enter.
Here we will cover two of the more important options. The first is
whatis -h
, or the long version, whatis --help
, for a short help screen.
Second is whatis --usage
which shows
you syntax. Again, the argument here is another command.
So why is whatis
an important command?
Well, it's the quickest way to find your bearings and remember what
a command does.
And now you know how to do that.
Okay, the best way to embed this in your memory is by typing in your own terminal window.
Find this on your Mac using a program called Terminal. On Linux use Terminal or Konsole, and currently Microsoft is adding this functionality to Windows 10.
Here we go, type whatis -h
with no
arguments, Enter
and look, the 13
options I mentioned, with the short and long versions.
Next, to see the syntax, type
whatis --usage
.
And last, let's go without options, include an argument whatis
and look, it pulls the short
description of whatis, just as we wanted.
Okay now you know how to use whatis
.
And you know the syntax for commands, options and arguments.
One last tip about the whatis
command.
Just like most in the help category, you don't have to worry about
messing things up, they're all pretty safe.
Okay, thanks for visiting today. I hope this was a fun exploration of
the whatis
command.
For an overview of all 100 videos, the 8 quizzes, a cheat sheet, the categories and a Q&A section, visit:
First off, subscribe at YouTube and follow @factorpad on Twitter for updates and new content notifications.
exit
command,
hit Back.clear
, click
Next./ factorpad.com / tech / linux-essentials / whatis-command.html
A newly-updated free resource. Connect and refer a friend today.