parallel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Feature Request: Special input value to create a barrier


From: Achim Gratz
Subject: Re: Feature Request: Special input value to create a barrier
Date: Sat, 07 Sep 2019 14:27:19 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux)

Achim Gratz writes:
> I could use a (configurable) special input value that creates a barrier
> (i.e. wait for all previous jobs to finish) upon parallel encountering
> it.  Usage would be something like:
>
> parallel --barrier + do_something '{}' ::: job1 job2 job3 + job4 job5 + job6 
> job7
>
> which should start the first three jobs, wait for them to finish, then
> starts the fourth and fifth job, waits again for these to finish, then
> the remaining sixth and seventh job are started in parallel.

FYI, I've been using this somewhat unwieldy invocation for now:

set $pd=( job1 job2 job3 + job4 job5 + job6 job7 )
echo $pd | sed 's/ + /\n/g' | xargs -I, dash -c "parallel do_something '{}' ::: 
,"

It does what I want and I can leave the remainder of the pipeline
untouched (which was running the jobs sequentially before, with no
barrier markers present).


Regards,
Achim.
-- 
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+

Factory and User Sound Singles for Waldorf Blofeld:
http://Synth.Stromeko.net/Downloads.html#WaldorfSounds




reply via email to

[Prev in Thread] Current Thread [Next in Thread]