jobs command: List the running task or processes in the current session
The jobs command will list the running, stopped, foreground and background jobs or task running in the current session.
Syntax
jobs [options]
The options are:
- -l
- -n
- -p
Report the process group ID and working directory of the jobs.
Display only jobs that have stopped or exited since last notified.
Displays only the process IDs for the process group leaders of the selected jobs.
run some jobs to see it in action:
xterm &
xterm &
Now run
jobs
This could be the output.
[1]- Running xterm & [2]+ Running xterm &


