On Linux, the
top command has a "batch mode":
top -b -n 1 to print the output a set number of times. On Mac, it seems that the
top command does not have batch mode (certainly the
-b option does not exist).
How can I emulate
top -b -n 1 on a Mac?