Bootstrap FreeKB - Linux Commands - info (information about a command)
Linux Commands - info (information about a command)

Updated:   |  Linux Commands articles

The info command can be used to view information about a command. 

 


View info page

The info command followed by a command will display information about a command if an info page exists. In this example, the info page for the ls (list) command will be displayed.

[root@server1 ~]# info ls

 


Keyword search

The -k or --apropos option can be used to search the info pages with a certain keyword. In this example, info pages that contain keyword printing are listed. In this examples, the info pages for the sort, cat, and pr commands contain keyword printing.

[root@server1 ~]# info -k printing
"(coreutils)sort invocation" -- --ignore-nonprinting
"(coreutils)cat invocation" -- --show-nonprinting
"(coreutils)pr invocation" -- --show-nonprinting
. . .

 


Locate an info file

The files that produce the info pages are typically stored in the /usr/share/info directory. The -w or --where or --location options can be used to find the exact file for a certain command. In this example, the file that contains the info page for the pr command is displayed.

[root@server1 ~]# info -w pr
/usr/share/info/coreutils.info.gz

 




Did you find this article helpful?

If so, consider buying me a coffee over at Buy Me A Coffee



Comments


Add a Comment


Please enter 85c91c in the box below so that we can be sure you are a human.