Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: why does "jobs | wc" not work?
- X-seq: zsh-users 5540
- From: Danek Duvall <duvall@xxxxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: Re: why does "jobs | wc" not work?
- Date: Tue, 26 Nov 2002 09:20:44 -0800
- In-reply-to: <20021126133333.GI1937@xxxxxx>
- Mail-followup-to: Danek Duvall <duvall@xxxxxxxxxxx>, zsh-users@xxxxxxxxxx
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <20021126124814.GH1937@xxxxxx> <29376.1038315921@xxxxxxx> <20021126133333.GI1937@xxxxxx>
On Tue, Nov 26, 2002 at 02:33:33PM +0100, Dominik Vogt wrote:
> jobs > x; I=0; while read X; do I=$[I+1]; done < x; echo $I
>
> Can anyone think of a more efficient way (speed does matter here)?
Assuming you have a recent enough version of zsh (4.0.x has it, but I'm
not sure when it was introduced):
echo $#jobstates
$jobdirs and $jobtexts are also available. They're in the zsh/parameter
module if you don't already have it loaded.
Danek
Messages sorted by:
Reverse Date,
Date,
Thread,
Author