PATH: How a Command Is Found

When you type a command's name, the shell looks for a program file of that name in each folder of PATH, in order, so "command not found" means none of them has it, and adding a folder to PATH lets you run its programs by name from anywhere.

Updated

Cheat sheet for the lesson PATH: How a Command Is Found: When you type a command's name, the shell looks for a program file of that name in each folder of PATH, in order, so "command not found" means none of them has it, and adding a folder to PATH lets you run its programs by name from anywhere.
Category
Bash
Level
Apprentice
Tags
linux, path, shell-builtin, unix, which