tags:

views:

16

answers:

1

The cmd finger -s gives output in the format :

Login     Name         Tty      Idle  Login Time    Office                   Office Phone
sentman       John Martin   pts/4          Oct  8 13:04 (professional.wp.mvit.in) 41552289

I just want the output to be in format

Login Name
sentman john Martin
+1  A: 

You can do:

finger -s | awk '{printf("%s %s\n", $1, $2);}'
codaddict