Skip to main content

New Template for Hotel Post am See

We replaced the template for an existing site with lots of content, changing functionality a bit and improving the responsible layout. Published in the beginning of 2018.

Find lines in big files

Get all lines in a big file containing some text:

cat filename  | egrep "141.71.45.20|159.205.92.236|171.33.185.210|"

Thanks to Günter!

Find files NOT of type

find . -type f -not -iname "*.jpg" -not -iname "*.jpeg" -not -iname "*.gif" -not -iname "*.png" -not -iname "*.pdf"

Useful!

Split files on lines

Split the file into multiple files at every 3rd line . i.e, First 3 lines into F1, next 3 lines into F2 and so on:

$ awk 'NR%3==1{x="F"++i;}{print > x}' filename

Subscribe to