Linux awk command

awk is mini language for text processing . could be useful when filtering columns or rows

sample text file

filter row

filter column

here this using ‘,’ as field separator (because default is space)

other parameters

NF — Number of Fields: total fields in the current line
NR — Number of Records: total records processed
RS — Record Separator: delimiter for records (default is a new line)
OFS — Output Field Separator: separator for fields’ output (default is one whitespace)
ORS — Output Record Separator: separator for records’ output (default is a new line)

use different separator for password file

use begin+end print table format

condition filtering

using if statement

or use ~

using loop + condition

--

--

A channel which focusing on developer growth and self improvement

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
LORY

A channel which focusing on developer growth and self improvement