Quantcast
Channel: How to assign an input parameter for a function including awk? - Ask Ubuntu
Browsing latest articles
Browse All 2 View Live

Answer by steeldriver for How to assign an input parameter for a function...

Awkk's -v argument takes a name=value pair, allowing you to use name as a variable inside your awk program. So tt() { r=$(j | awk -v id="$2" 'FNR=id && NR {print $1}'); jj $r; } (TBH I'm not...

View Article



How to assign an input parameter for a function including awk?

I am making some shortcuts for my account in a computation cluster. When I submit a job, the system assigns a job-ID (JOBID) to my calculation. To list all my calculations, I made an alias alias...

View Article
Browsing latest articles
Browse All 2 View Live




Latest Images