#159 Awk control file
Create awk control file func1.awk
function green(s) {
printf "\033[1;32m" s "\033[0m\n"
}
BEGIN {
FS=":"
green(" Name: UID: Shell:")
}
{
printf "%10s %4d %17s\n",$1,$3,$7
}
Command to run awk control file is
awk -f func1.awk /etc/passwd
Last Updated on 2021-02-09 by gantovnik
Recent Comments