look
file managementLinux/Unix
The look command is one of the most frequently used commands in Linux/Unix-like operating systems. look Display lines beginning with a given string
Quick Reference
Command Name:
look
Category:
file management
Platform:
Linux/Unix
Basic Usage:
look [options] [arguments]
Common Use Cases
Syntax
look [options] string [file]
Options
| Option | Description |
|---|---|
-a, --alternative |
Use the alternative dictionary file |
-b, --binary |
Use binary search on the file (file must be sorted) |
-d, --ignore-case |
Case-insensitive search |
-f, --ignore-case |
Case-insensitive search (alternate form) |
-t, --terminate CHAR |
Define the string termination character |
-h, --help |
Display help information and exit |
-V, --version |
Display version information and exit |
Examples
How to Use These Examples
The examples below show common ways to use the look command. Try them in your terminal to see the results. You can copy any example by clicking on the code block.