Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?

Liste des GroupesRevenir à cu shell 
Sujet : Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?
De : naddy (at) *nospam* mips.inka.de (Christian Weisgerber)
Groupes : comp.unix.shell
Date : 12. May 2024, 00:44:03
Autres entêtes
Message-ID : <slrnv3vt5j.1gfp.naddy@lorvorc.mips.inka.de>
References : 1
User-Agent : slrn/1.0.3 (FreeBSD)
On 2024-05-11, Kenny McCormack <gazelle@shell.xmission.com> wrote:

I tried it a few times, but could not get back the #1 slot.

If no job is running, a new job gets 1, otherwise new jobs are
numbered consecutively.

I've only cursorily glanced over the code history, but I think it's
been like this in csh(1) since its initial import into the BSD
repository in 1980, and other shells have copied the behavior.

Eventually, I exited jobs 2 & 3, and then re-launched ssh somesystem and it
came out as job #1, after which I was able to re-construct jobs 2 & 3 and
then things were as they should be.  But should this hack be necessary?

As I accidentally discovered while looking at the code, csh(1) tries
to recycle smaller job IDs once it goes beyond 9.  tcsh(1) preserves
that behavior to this day.

I offer no opinion on this, nor on the Plan 9 assertion that job
control is a poor hack and you should just open another window.

--
Christian "naddy" Weisgerber                          naddy@mips.inka.de

Date Sujet#  Auteur
11 May 24 * When/why does the shell (bash) (sometimes) not re-cycle job IDs?15Kenny McCormack
12 May 24 `* Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?14Christian Weisgerber
12 May 24  +* Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?12Lawrence D'Oliveiro
12 May 24  i+- Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?1vallor
12 May 24  i+* Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?6Janis Papanagnou
12 May 24  ii+* Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?4Kenny McCormack
12 May 24  iii`* Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?3Janis Papanagnou
12 May 24  iii `* Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?2Kenny McCormack
13 May 24  iii  `- Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?1Janis Papanagnou
12 May 24  ii`- Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?1Lawrence D'Oliveiro
12 May 24  i+- Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?1Kenny McCormack
12 May 24  i`* Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?3Christian Weisgerber
12 May 24  i `* Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?2Lawrence D'Oliveiro
13 May 24  i  `- Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?1Christian Weisgerber
12 May 24  `- Re: When/why does the shell (bash) (sometimes) not re-cycle job IDs?1Kenny McCormack

Haut de la page

Les messages affichés proviennent d'usenet.

NewsPortal