Remove sections from each line of files
Opt | Long Option | Description |
---|---|---|
-c list | –characters=list | Extract the portion of the line defined by list. |
The list may consist of one or more comma-separated numerical ranges. | ||
-f list | –fields=list | Extract one or more fields from the line as defined by list |
-d delim | –delimeter=delim | When -f is specified, use delim as the field delimiting char |
–complement | Extract the entire line except portions specified by -c and/or -f |
cut Selection Options
Example: cut -d ':' -f 1 /etc/passwd | head