O'Reilly logo

A Practical Guide to Red Hat® Linux® 8 by Mark G. Sobell

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

which

Shows where in your path a command is located

which command-list

The which utility searches the directories listed in the PATH variable and displays the absolute pathname of each file in command-list that it finds.

Arguments

The command-list contains one or more commands (utilities) that which searches for. For each command which searches the directories listed in your PATH environment variable, in order, and displays the full pathname of the first command (executable file) it finds. If which does not locate a command, it displays an error message.

Options

--all

-a all Displays all matching executable files in PATH, not just the first.

--read-alias

-i Reads aliases from standard input and reports on matching aliases in addition to executable ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required