File: shell.awk

package info (click to toggle)
mawk 1.3.4.20200120-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 1,916 kB
  • sloc: ansic: 16,165; sh: 3,515; yacc: 1,125; awk: 722; makefile: 251
file content (16 lines) | stat: -rw-r--r-- 367 bytes parent folder | download | duplicates (11)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
# Ben Myers <0003571400@mcimail.com>

# Test pipes under DOS. comment/uncomment print statements below
BEGIN {
# redirection done by shelled command
system("dir *.* /b >pippo.")
lcount = 0
}
{
# print
# Below is redirection done by mawk
# print >"pippo2."
print $0 | "sort"
lcount++
}
END { print "mawk NR line count=" NR " our line count=" lcount " lines in pippo"}