Re:Basic Scripting with Awk and Gnuplot
by yiyus on Thursday January 21, 2021 @06:40PM
(#25866247)
There is no need to initialize variables with -v. You could just do:
[ Parent
| on HN ]
Re:Basic Scripting with Awk and Gnuplot
by tragomaskhalos on Friday January 22, 2021 @03:50AM
(#25869723)
Or use a begin block:
'BEGIN { j = 1 }
/Time/ …
'
I find it best to restrict the use -v to injecting environment variables into my awk scripts.