[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Idea: jobs(1) -i to print only :%ID:s
From: |
alex xmb sw ratchev |
Subject: |
Re: Idea: jobs(1) -i to print only :%ID:s |
Date: |
Thu, 9 Nov 2023 22:24:48 +0100 |
On Thu, Nov 9, 2023, 10:18 PM Andreas Schwab <schwab@linux-m68k.org> wrote:
> On Nov 09 2023, Greg Wooledge wrote:
>
> > re='^\[([0-9]+)\]'
> > jobspecs=()
> > while IFS= read -r line; do
> > if [[ $line =~ $re ]]; then
> > jobspecs+=( "%${BASH_REMATCH[1]}" )
> > fi
> > done < <(jobs -l)
>
> That fails for multi-line commands that happen to contain matches for
> re.
>
> $ (sleep 100; printf $'\n[100]\n') &
>
a suggestion for the future , that bash coding keywords have own isf osf
var following , so i can have null or other separated , by code builtins ..
--
> Andreas Schwab, schwab@linux-m68k.org
> GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510 2552 DF73 E780 A9DA AEC1
> "And now for something completely different."
>
>
- Idea: jobs(1) -i to print only :%ID:s, Steffen Nurpmeso, 2023/11/08
- Re: Idea: jobs(1) -i to print only :%ID:s, Steffen Nurpmeso, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, Steffen Nurpmeso, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, alex xmb sw ratchev, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, alex xmb sw ratchev, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, Steffen Nurpmeso, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, Greg Wooledge, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, alex xmb sw ratchev, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, Steffen Nurpmeso, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, Andreas Schwab, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s,
alex xmb sw ratchev <=
- Re: Idea: jobs(1) -i to print only :%ID:s, Greg Wooledge, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, alex xmb sw ratchev, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, alex xmb sw ratchev, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, Steffen Nurpmeso, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, Robert Elz, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, Steffen Nurpmeso, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, Steffen Nurpmeso, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, Robert Elz, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, Steffen Nurpmeso, 2023/11/09
- Re: Idea: jobs(1) -i to print only :%ID:s, alex xmb sw ratchev, 2023/11/09