Awk scripting use of fi (awk ‘{print $NF}fi’)

awk '{print $NF}fi'

  • what is that fi for?
  • what’s the difference if I will not include it, like I only want to do —> awk ‘{print $NF}’


Seems like a typo to me. Is there more to that line?

Linux sysadmin blog - Linux/Unix Howtos and Tutorials - Linux bash shell scripting wiki