Redhat Linux 中的“jobs”命令是什么?

Redhat Linux 中的“jobs”命令是什么?

Linux 中的命令是什么jobs以及如何使用它?请举一些例子。

答案1

最有可能的jobs是 shell 中的内置命令。如果您使用bashthen 运行并在行的开头man bash搜索(按 开始搜索,然后按)。您应该看到以下内容:jobs/^ *jobs

jobs [-lnprs] [ jobspec ... ]
jobs -x command [ args ... ]
        The first form lists the active jobs.  The options have the  following  meanings:
        -l     List process IDs in addition to the normal information.
        -n     Display information only about jobs that have changed status since the
               user was last notified of their status.
        -p     List only the process ID of the job's process group leader.
        -r     Restrict output to running jobs.
        -s     Restrict output to stopped jobs.

一个简单的jobs输出示例:

$ jobs
[1]  - running    firefox-bin
[2]  + running    emacs .zshrc

相关内容