Search and Filtering

which

Shows the executable path that would run for a command.

which searches PATH and prints the executable file used for a command name.

Syntax
which command

Arguments explained

  • command is the executable name to resolve.

Common examples

Find python
which python3

Shows the python3 executable selected by PATH.

Check if a tool exists
which rsync

Prints a path if rsync is installed and visible.

which Command
FieldDetails
Commandwhich
CategorySearch and Filtering
Primary useShows the executable path that would run for a command.
Syntaxwhich command