mirror of
https://git.savannah.gnu.org/git/parallel.git
synced 2024-11-25 23:47:53 +00:00
bug #42041: Implement $PARALLEL_JOBSLOT {%}. tutorial + test.
This commit is contained in:
parent
5f30c90c35
commit
511623aa70
|
@ -238,6 +238,8 @@ New in this release:
|
||||||
|
|
||||||
* Export quicklooks with vector overlay using TuiView http://spectraldifferences.wordpress.com/2014/03/08/export-quicklooks-with-vector-overlay-using-tuiview/
|
* Export quicklooks with vector overlay using TuiView http://spectraldifferences.wordpress.com/2014/03/08/export-quicklooks-with-vector-overlay-using-tuiview/
|
||||||
|
|
||||||
|
* GNU Parallel指南 http://my.oschina.net/enyo/blog/271612
|
||||||
|
|
||||||
* GNU parallelで違和感 http://jarp.does.notwork.org/diary/201405c.html#201405301
|
* GNU parallelで違和感 http://jarp.does.notwork.org/diary/201405c.html#201405301
|
||||||
|
|
||||||
* Bug fixes and man page updates.
|
* Bug fixes and man page updates.
|
||||||
|
|
|
@ -1314,8 +1314,8 @@ Instead of basing the percentage on the number of \s-1CPU\s0 cores
|
||||||
.Vb 1
|
.Vb 1
|
||||||
\& parallel \-\-use\-cpus\-instead\-of\-cores \-N0 sleep 1 ::: {1..128}
|
\& parallel \-\-use\-cpus\-instead\-of\-cores \-N0 sleep 1 ::: {1..128}
|
||||||
.Ve
|
.Ve
|
||||||
.SS "Interactiveness"
|
.SS "Interactivity"
|
||||||
.IX Subsection "Interactiveness"
|
.IX Subsection "Interactivity"
|
||||||
\&\s-1GNU\s0 Parallel can ask the user if a command should be run using \-\-interactive:
|
\&\s-1GNU\s0 Parallel can ask the user if a command should be run using \-\-interactive:
|
||||||
.PP
|
.PP
|
||||||
.Vb 1
|
.Vb 1
|
||||||
|
|
|
@ -63,7 +63,7 @@
|
||||||
<ul>
|
<ul>
|
||||||
|
|
||||||
<li><a href="#number_of_simultaneous_jobs">Number of simultaneous jobs</a></li>
|
<li><a href="#number_of_simultaneous_jobs">Number of simultaneous jobs</a></li>
|
||||||
<li><a href="#interactiveness">Interactiveness</a></li>
|
<li><a href="#interactivity">Interactivity</a></li>
|
||||||
<li><a href="#timing">Timing</a></li>
|
<li><a href="#timing">Timing</a></li>
|
||||||
<li><a href="#progress">Progress</a></li>
|
<li><a href="#progress">Progress</a></li>
|
||||||
<li><a href="#termination">Termination</a></li>
|
<li><a href="#termination">Termination</a></li>
|
||||||
|
@ -906,7 +906,7 @@ GNU Parallel can base it on the number of CPUs:</p>
|
||||||
parallel --use-cpus-instead-of-cores -N0 sleep 1 ::: {1..128}</pre>
|
parallel --use-cpus-instead-of-cores -N0 sleep 1 ::: {1..128}</pre>
|
||||||
<p>
|
<p>
|
||||||
</p>
|
</p>
|
||||||
<h2><a name="interactiveness">Interactiveness</a></h2>
|
<h2><a name="interactivity">Interactivity</a></h2>
|
||||||
<p>GNU Parallel can ask the user if a command should be run using --interactive:</p>
|
<p>GNU Parallel can ask the user if a command should be run using --interactive:</p>
|
||||||
<pre>
|
<pre>
|
||||||
parallel --interactive echo ::: 1 2 3</pre>
|
parallel --interactive echo ::: 1 2 3</pre>
|
||||||
|
|
Binary file not shown.
|
@ -923,7 +923,7 @@ GNU Parallel can base it on the number of CPUs:
|
||||||
|
|
||||||
parallel --use-cpus-instead-of-cores -N0 sleep 1 ::: {1..128}
|
parallel --use-cpus-instead-of-cores -N0 sleep 1 ::: {1..128}
|
||||||
|
|
||||||
=head2 Interactiveness
|
=head2 Interactivity
|
||||||
|
|
||||||
GNU Parallel can ask the user if a command should be run using --interactive:
|
GNU Parallel can ask the user if a command should be run using --interactive:
|
||||||
|
|
||||||
|
|
|
@ -38,13 +38,13 @@ parallel -S tcsh@localhost --env SPC echo 'a"$SPC"b' ::: 5
|
||||||
echo '### Test --env for \n and \\ - single and double (bash only) - no output is good'
|
echo '### Test --env for \n and \\ - single and double (bash only) - no output is good'
|
||||||
perl -e 'for(10,92) { printf "%c%c %c%d\0",$_,$_,$_,$_ }' | stdout parallel --nice 19 -j4 -k -I // --arg-sep _ -0 V=// V2=V2=// parallel -k -j1 -S 2/:,2/lo --env V,V2 echo \''"{}$V$V2"'\' ::: {#} {#} {#} {#} | sort | uniq -c | grep -v ' 4 '|grep -v xauth |grep -v X11
|
perl -e 'for(10,92) { printf "%c%c %c%d\0",$_,$_,$_,$_ }' | stdout parallel --nice 19 -j4 -k -I // --arg-sep _ -0 V=// V2=V2=// parallel -k -j1 -S 2/:,2/lo --env V,V2 echo \''"{}$V$V2"'\' ::: {#} {#} {#} {#} | sort | uniq -c | grep -v ' 4 '|grep -v xauth |grep -v X11
|
||||||
|
|
||||||
echo '### Test --env for \n and \\ - single and double (*csh only) - no output is good'
|
echo '### Test --env for \n and \\ - single and double (*csh only) - no output is good but csh fails'
|
||||||
perl -e 'for(10,92) { printf "%c%c %c%d\0",$_,$_,$_,$_ }' | stdout parallel --nice 19 -j4 -k -I // --arg-sep _ -0 V=// V2=V2=// parallel -k -j1 -S 2/tcsh@lo,2/csh@lo --env V,V2 echo \''"{}$V$V2"'\' ::: {#} {#} {#} {#} | sort | uniq -c | grep -v ' 4 '|grep -v xauth |grep -v X11
|
perl -e 'for(10,92) { printf "%c%c %c%d\0",$_,$_,$_,$_ }' | stdout parallel --nice 19 -j4 -k -I // --arg-sep _ -0 V=// V2=V2=// parallel -k -j1 -S 2/tcsh@lo,2/csh@lo --env V,V2 echo \''"{}$V$V2"'\' ::: {#} {#} {#} {#} | sort | uniq -c | grep -v ' 4 '|grep -v xauth |grep -v X11
|
||||||
|
|
||||||
echo '### Test --env for \n and \\ - single and double --onall (bash only) - no output is good'
|
echo '### Test --env for \n and \\ - single and double --onall (bash only) - no output is good'
|
||||||
perl -e 'for(10,92) { printf "%c%c %c%d\0",$_,$_,$_,$_ }' | stdout parallel --nice 19 -j4 -k -I // --arg-sep _ -0 V=// V2=V2=// parallel -k -j1 -S :,lo --onall --env V,V2 echo \''"{}$V$V2"'\' ::: {#} | sort | uniq -c | grep -v ' 4 '|grep -v xauth |grep -v X11
|
perl -e 'for(10,92) { printf "%c%c %c%d\0",$_,$_,$_,$_ }' | stdout parallel --nice 19 -j4 -k -I // --arg-sep _ -0 V=// V2=V2=// parallel -k -j1 -S :,lo --onall --env V,V2 echo \''"{}$V$V2"'\' ::: {#} | sort | uniq -c | grep -v ' 4 '|grep -v xauth |grep -v X11
|
||||||
|
|
||||||
echo '### Test --env for \n and \\ - single and double --onall (*csh only) - no output is good'
|
echo '### Test --env for \n and \\ - single and double --onall (*csh only) - no output is good but csh fails'
|
||||||
perl -e 'for(10,92) { printf "%c%c %c%d\0",$_,$_,$_,$_ }' | stdout parallel --nice 19 -j4 -k -I // --arg-sep _ -0 V=// V2=V2=// parallel -k -j1 -S 1/tcsh@lo,1/csh@lo --onall --env V,V2 echo \''"{}$V$V2"'\' ::: {#} | sort | uniq -c | grep -v ' 2 '|grep -v xauth |grep -v X11
|
perl -e 'for(10,92) { printf "%c%c %c%d\0",$_,$_,$_,$_ }' | stdout parallel --nice 19 -j4 -k -I // --arg-sep _ -0 V=// V2=V2=// parallel -k -j1 -S 1/tcsh@lo,1/csh@lo --onall --env V,V2 echo \''"{}$V$V2"'\' ::: {#} | sort | uniq -c | grep -v ' 2 '|grep -v xauth |grep -v X11
|
||||||
|
|
||||||
echo '### Test --env for \160 - which kills csh - single and double - no output is good'
|
echo '### Test --env for \160 - which kills csh - single and double - no output is good'
|
||||||
|
|
|
@ -45,5 +45,6 @@ echo '### nice and tcsh and Bug #33995: Jobs executed with sh instead of $SHELL'
|
||||||
|
|
||||||
echo '### bug #42041: Implement $PARALLEL_JOBSLOT'
|
echo '### bug #42041: Implement $PARALLEL_JOBSLOT'
|
||||||
parallel -k --slotreplace ,, -j2 echo ,, ::: {1..4}
|
parallel -k --slotreplace ,, -j2 echo ,, ::: {1..4}
|
||||||
|
parallel -k -j2 echo {%} ::: {1..4}
|
||||||
|
|
||||||
EOF
|
EOF
|
||||||
|
|
|
@ -3,40 +3,57 @@ a 2 spaces b 1
|
||||||
a 2 spaces b 1
|
a 2 spaces b 1
|
||||||
a 2 spaces b 1
|
a 2 spaces b 1
|
||||||
a 2 spaces b 1
|
a 2 spaces b 1
|
||||||
|
MANPATH: Undefined variable.
|
||||||
a 2 spaces b 1
|
a 2 spaces b 1
|
||||||
a 2 spaces b a > My brother's 12" records < b 2
|
a 2 spaces b a > My brother's 12" records < b 2
|
||||||
a 2 spaces b a > My brother's 12" records < b 2
|
a 2 spaces b a > My brother's 12" records < b 2
|
||||||
a 2 spaces b a > My brother's 12" records < b 2
|
a 2 spaces b a > My brother's 12" records < b 2
|
||||||
a 2 spaces b a > My brother's 12" records < b 2
|
a 2 spaces b a > My brother's 12" records < b 2
|
||||||
|
MANPATH: Undefined variable.
|
||||||
a 2 spaces b a > My brother's 12" records < b 2
|
a 2 spaces b a > My brother's 12" records < b 2
|
||||||
a 2 spaces b a > My brother's 12" records < b 3
|
a 2 spaces b a > My brother's 12" records < b 3
|
||||||
a 2 spaces b a > My brother's 12" records < b 3
|
a 2 spaces b a > My brother's 12" records < b 3
|
||||||
a 2 spaces b a > My brother's 12" records < b 3
|
a 2 spaces b a > My brother's 12" records < b 3
|
||||||
a 2 spaces b a > My brother's 12" records < b 3
|
a 2 spaces b a > My brother's 12" records < b 3
|
||||||
|
MANPATH: Undefined variable.
|
||||||
a 2 spaces b a > My brother's 12" records < b 3
|
a 2 spaces b a > My brother's 12" records < b 3
|
||||||
a \'"b 4
|
a \'"b 4
|
||||||
a \'"b 4
|
a \'"b 4
|
||||||
a \'"b 4
|
a \'"b 4
|
||||||
a \'"b 4
|
a \'"b 4
|
||||||
|
MANPATH: Undefined variable.
|
||||||
a \'"b 4
|
a \'"b 4
|
||||||
a' * ? >o <i*? ][\!#¤%=( ) | }b 5
|
a' * ? >o <i*? ][\!#¤%=( ) | }b 5
|
||||||
a' * ? >o <i*? ][\!#¤%=( ) | }b 5
|
a' * ? >o <i*? ][\!#¤%=( ) | }b 5
|
||||||
a' * ? >o <i*? ][\!#¤%=( ) | }b 5
|
a' * ? >o <i*? ][\!#¤%=( ) | }b 5
|
||||||
a' * ? >o <i*? ][\!#¤%=( ) | }b 5
|
a' * ? >o <i*? ][\!#¤%=( ) | }b 5
|
||||||
|
MANPATH: Undefined variable.
|
||||||
a' * ? >o <i*? ][\!#¤%=( ) | }b 5
|
a' * ? >o <i*? ][\!#¤%=( ) | }b 5
|
||||||
### Test --env for \n and \\ - single and double (bash only) - no output is good
|
### Test --env for \n and \\ - single and double (bash only) - no output is good
|
||||||
8
|
8
|
||||||
8
|
8
|
||||||
### Test --env for \n and \\ - single and double (*csh only) - no output is good
|
### Test --env for \n and \\ - single and double (*csh only) - no output is good but csh fails
|
||||||
8
|
2 2\ \92V2=\ \92
|
||||||
8
|
2 2\\ \92V2=\\ \92
|
||||||
|
16 : Command not found.
|
||||||
|
8 Unmatched ".
|
||||||
|
16 \ : Command not found.
|
||||||
### Test --env for \n and \\ - single and double --onall (bash only) - no output is good
|
### Test --env for \n and \\ - single and double --onall (bash only) - no output is good
|
||||||
2 1
|
2 1
|
||||||
2 10
|
2 10
|
||||||
2 10V2=
|
2 10V2=
|
||||||
2 2\\ \92V2=\\ \92
|
2 2\\ \92V2=\\ \92
|
||||||
### Test --env for \n and \\ - single and double --onall (*csh only) - no output is good
|
### Test --env for \n and \\ - single and double --onall (*csh only) - no output is good but csh fails
|
||||||
4
|
1 2\ \92V2=\ \92
|
||||||
4
|
1 2\\ \92V2=\\ \92
|
||||||
|
8 : Command not found.
|
||||||
|
4 Unmatched ".
|
||||||
|
8 \ : Command not found.
|
||||||
### Test --env for \160 - which kills csh - single and double - no output is good
|
### Test --env for \160 - which kills csh - single and double - no output is good
|
||||||
|
2 1 160V2= 160
|
||||||
|
1 MANPATH: Undefined variable.
|
||||||
|
1 1 160V2= 160
|
||||||
### Test --env for \160 - which kills csh - single and double --onall - no output is good
|
### Test --env for \160 - which kills csh - single and double --onall - no output is good
|
||||||
|
2 1 160V2= 160
|
||||||
|
1 MANPATH: Undefined variable.
|
||||||
|
1 1 160V2= 160
|
||||||
|
|
|
@ -28,3 +28,7 @@ tcsh 2
|
||||||
2
|
2
|
||||||
1
|
1
|
||||||
2
|
2
|
||||||
|
1
|
||||||
|
2
|
||||||
|
1
|
||||||
|
2
|
||||||
|
|
Loading…
Reference in a new issue