O'Reilly logo

Korn Shell: Unix and Linux Programming Manual, Third Edition, The by Anatole Olczak

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Job Names

Most people use the job number to refer to a job, because one number is easy to remember. However, jobs can be referred to in a number of other ways: by process id, current/previous job, or all or part of a job name. If we had these jobs:

					$ jobs —l
					[3]  + 466 Stopped          split —5000 hugefile
					[2]  — 465 Running          find / —name  —print &
					[1]    463 Running          sleep 25 &
				

then the split job could be referred to as %3, %+, %%, 466, %split, or %?sp, the find job could be referred to as %2, %–, 465, %find, or %?f, and the sleep could be referred to as %1, 463, %sleep, or %?sl.

Table 5.2. Job Names
%n job n
%+, %% current job
%– previous job
%string job whose name begins with string
%?string job that matches part or all of string

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required