terminal.cab

All commands

which

Topic: Shell and scripts

Program: which

Shows which program file a command runs.

Package: basis-info

Usage

which [-a] NAME...

Description

Show which program file runs for each NAME, searched in the directories of PATH.

Options in the simulator

1 more options of the real program, not in the simulator yet
  • -s not in the simulator yet

    Explanation to come

Examples

From the lesson Getting help
which ls
/usr/bin/ls

Try it in the terminal

From the command of the day: type and which
type cd
cd is a shell builtin
type ls
ls is /usr/bin/ls
which ls
/usr/bin/ls

Try it in the terminal

Where you learn it

Lessons

Command of the day

All commands