Linux stream commands

Card Set Information

Author:
Svenxix
ID:
100900
Filename:
Linux stream commands
Updated:
2011-09-10 16:47:00
Tags:
linux commands stream
Folders:

Description:
Basic linux command line options for stream control commands
Show Answers:

Home > Flashcards > Print Preview

The flashcards below were created by user Svenxix on FreezingBlue Flashcards. What would you like to do?


  1. wc
    • -c count characters
    • -w count words
    • -l count lines
    • -L print the length of the longest line
  2. grep
    • -i => matching is case insensitive
    • -E => use regular expression
    • -n => include line numbers in output
    • -v => include lines that do not include the following words
    • -B <integer> => include <integer> lines before searched term
  3. sed
    • sed 's/find/replace/' => replaces first intance of find with replace
    • sed 's/find/replace/g' => replaces all instances of find with replace.
  4. tr
    • tr <options> <set1> <set2>
    • replaces set1 with set2.

    • -d => deletes set1
    • -s => squeeze, remove duplicate letters included in set1
  5. sort
    • sort <options> filename . . .
    • -n => sort numericaly
    • -r => sort in reverse order
    • -m => do not sort, only merge
    • -t <separator> => use the character separator as a column separator
    • -k <number> => sort by this column number
    • -o <filename> => send output to this file instead of STDOUT
  6. uniq
    • uniq <options> <filename. . .>
    • must be fed sorted data
    • -i => ignore case
    • -D => print duplicate lines
    • -d => only print duplicate lines
    • -u => only print unique lines
    • -c => prefix lines by the number of occurrences

What would you like to do?

Home > Flashcards > Print Preview