Name

jobs

The built-in command jobs lists the jobs running in your current shell:

jobs
[1]-  Running                 emacs myfile &
[2]+  Stopped                 wc -l bigfile

The integer on the left is the job number, and the plus sign identifies the default job affected by the fg (foreground) and bg (background) commands.

Get Macintosh Terminal Pocket Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.