Jade plant (Crassula ovata)

Tag(s):

To copy faster than cp, use tar|pv|tar

Tag(s):

To copy faster than cp, use tar|pv|tar. See performance benchmark at https://github.com/limelime/mtran/blob/master/benchmark/benchmark-results.md.

Sort multiple columns

Tag(s):

cat people.txt
#   john; smith; 49
#   amanda; bush; 55
#   john; kidman; 55
#   john; bush; -9
#   amanda; bush; 1
 

Delete all the lines after PATTERN

Tag(s):

# To delete all the lines after PATTERN, use this
sed '/PATTERN/,$d' input.txt

https://nixtricks.wordpress.com/2013/01/09/sed-delete-the-lines-lying-in-between-two-patterns/

Get mutiple line text between 2 patterns

Tag(s):

# Note: PATTERN-1 & PATTERN-2 will be also included in your result.
sed -n '/PATTERN-1/,/PATTERN-2/p' input.txt

http://stackoverflow.com/questions/15685471/sed-get-text-between-lines

Pages

Subscribe to OpenWritings.net RSS