Released as 20130622 ('Snowden').

This commit is contained in:
Ole Tange 2013-06-22 14:50:48 +02:00
parent f813f02abf
commit 85ab036518
17 changed files with 155 additions and 110 deletions

23
NEWS
View file

@ -1,3 +1,26 @@
20130622
* --xapply now recycles arguments if an input source has more
arguments than others.
* The sleep time between jobs is now both increased and decreased
exponentially.
* 10 seconds installation check the signature using GnuPG if GnuPG is
installed.
* Developer job asking for GNU Parallel expertise.
http://careers.stackoverflow.com/jobs/35562/developer-big-data-geo-and-web-climate-central
* A small utility program to run youtube-dl in parallel.
https://github.com/dlh/youtube-dl-parallel
* Parallelizing Freesurfer:
http://blog.cogneurostats.com/?p=148
* Bug fixes and man page updates.
20130522 20130522
* --ctrlc is now default if --pipe is not used; thus making it * --ctrlc is now default if --pipe is not used; thus making it

12
README
View file

@ -40,9 +40,9 @@ document.
Full installation of GNU Parallel is as simple as: Full installation of GNU Parallel is as simple as:
wget http://ftpmirror.gnu.org/parallel/parallel-20130522.tar.bz2 wget http://ftpmirror.gnu.org/parallel/parallel-20130622.tar.bz2
bzip2 -dc parallel-20130522.tar.bz2 | tar xvf - bzip2 -dc parallel-20130622.tar.bz2 | tar xvf -
cd parallel-20130522 cd parallel-20130622
./configure && make && make install ./configure && make && make install
@ -51,9 +51,9 @@ Full installation of GNU Parallel is as simple as:
If you are not root you can add ~/bin to your path and install in If you are not root you can add ~/bin to your path and install in
~/bin and ~/share: ~/bin and ~/share:
wget http://ftpmirror.gnu.org/parallel/parallel-20130522.tar.bz2 wget http://ftpmirror.gnu.org/parallel/parallel-20130622.tar.bz2
bzip2 -dc parallel-20130522.tar.bz2 | tar xvf - bzip2 -dc parallel-20130622.tar.bz2 | tar xvf -
cd parallel-20130522 cd parallel-20130622
./configure --prefix=$HOME && make && make install ./configure --prefix=$HOME && make && make install
Or if your system lacks 'make' you can simply copy src/parallel Or if your system lacks 'make' you can simply copy src/parallel

20
configure vendored
View file

@ -1,6 +1,6 @@
#! /bin/sh #! /bin/sh
# Guess values for system-dependent variables and create Makefiles. # Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.68 for parallel 20130522. # Generated by GNU Autoconf 2.68 for parallel 20130622.
# #
# Report bugs to <bug-parallel@gnu.org>. # Report bugs to <bug-parallel@gnu.org>.
# #
@ -559,8 +559,8 @@ MAKEFLAGS=
# Identity of this package. # Identity of this package.
PACKAGE_NAME='parallel' PACKAGE_NAME='parallel'
PACKAGE_TARNAME='parallel' PACKAGE_TARNAME='parallel'
PACKAGE_VERSION='20130522' PACKAGE_VERSION='20130622'
PACKAGE_STRING='parallel 20130522' PACKAGE_STRING='parallel 20130622'
PACKAGE_BUGREPORT='bug-parallel@gnu.org' PACKAGE_BUGREPORT='bug-parallel@gnu.org'
PACKAGE_URL='' PACKAGE_URL=''
@ -1176,7 +1176,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing. # Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh. # This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF cat <<_ACEOF
\`configure' configures parallel 20130522 to adapt to many kinds of systems. \`configure' configures parallel 20130622 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]... Usage: $0 [OPTION]... [VAR=VALUE]...
@ -1242,7 +1242,7 @@ fi
if test -n "$ac_init_help"; then if test -n "$ac_init_help"; then
case $ac_init_help in case $ac_init_help in
short | recursive ) echo "Configuration of parallel 20130522:";; short | recursive ) echo "Configuration of parallel 20130622:";;
esac esac
cat <<\_ACEOF cat <<\_ACEOF
@ -1309,7 +1309,7 @@ fi
test -n "$ac_init_help" && exit $ac_status test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then if $ac_init_version; then
cat <<\_ACEOF cat <<\_ACEOF
parallel configure 20130522 parallel configure 20130622
generated by GNU Autoconf 2.68 generated by GNU Autoconf 2.68
Copyright (C) 2010 Free Software Foundation, Inc. Copyright (C) 2010 Free Software Foundation, Inc.
@ -1326,7 +1326,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake. running configure, to aid debugging if configure makes a mistake.
It was created by parallel $as_me 20130522, which was It was created by parallel $as_me 20130622, which was
generated by GNU Autoconf 2.68. Invocation command line was generated by GNU Autoconf 2.68. Invocation command line was
$ $0 $@ $ $0 $@
@ -2141,7 +2141,7 @@ fi
# Define the identity of the package. # Define the identity of the package.
PACKAGE='parallel' PACKAGE='parallel'
VERSION='20130522' VERSION='20130622'
cat >>confdefs.h <<_ACEOF cat >>confdefs.h <<_ACEOF
@ -2704,7 +2704,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their # report actual input values of CONFIG_FILES etc. instead of their
# values after options handling. # values after options handling.
ac_log=" ac_log="
This file was extended by parallel $as_me 20130522, which was This file was extended by parallel $as_me 20130622, which was
generated by GNU Autoconf 2.68. Invocation command line was generated by GNU Autoconf 2.68. Invocation command line was
CONFIG_FILES = $CONFIG_FILES CONFIG_FILES = $CONFIG_FILES
@ -2766,7 +2766,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\ ac_cs_version="\\
parallel config.status 20130522 parallel config.status 20130622
configured by $0, generated by GNU Autoconf 2.68, configured by $0, generated by GNU Autoconf 2.68,
with options \\"\$ac_cs_config\\" with options \\"\$ac_cs_config\\"

View file

@ -1,4 +1,4 @@
AC_INIT([parallel], [20130522], [bug-parallel@gnu.org]) AC_INIT([parallel], [20130622], [bug-parallel@gnu.org])
AM_INIT_AUTOMAKE([-Wall -Werror foreign]) AM_INIT_AUTOMAKE([-Wall -Werror foreign])
AC_CONFIG_HEADERS([config.h]) AC_CONFIG_HEADERS([config.h])
AC_CONFIG_FILES([ AC_CONFIG_FILES([

View file

@ -1,5 +1,5 @@
replace: true replace: true
version: 1.1 version: 1.2
directory: parallel directory: parallel
filename: parallel-20100424.tar.bz2 filename: parallel-20100424.tar.bz2
symlink: parallel-20100424.tar.bz2 parallel-latest.tar.bz2 symlink: parallel-20100424.tar.bz2 parallel-latest.tar.bz2

View file

@ -183,21 +183,32 @@ cc:Sandro Cazzaniga <kharec@mandriva.org>,
Ryoichiro Suzuki <ryoichiro.suzuki@gmail.com>, Ryoichiro Suzuki <ryoichiro.suzuki@gmail.com>,
Jesse Alama <jesse.alama@gmail.com> Jesse Alama <jesse.alama@gmail.com>
Subject: GNU Parallel 20130622 ('') released Subject: GNU Parallel 20130622 ('Snowden') released
GNU Parallel 20130622 ('') has been released. It is GNU Parallel 20130622 ('Snowden') has been released. It is
available for download at: http://ftp.gnu.org/gnu/parallel/ available for download at: http://ftp.gnu.org/gnu/parallel/
The changes for this release has been in the core of the code, so this Very few changes so this can be considered a stable release.
release should be considered beta quality.
New in this release: New in this release:
* Developer job asking for GNU Parallel expertise: * --xapply now recycles arguments if an input source has more
arguments than others.
* The sleep time between jobs is now both increased and decreased
exponentially.
* 10 seconds installation check the signature using GnuPG if GnuPG is
installed.
* Developer job asking for GNU Parallel expertise.
http://careers.stackoverflow.com/jobs/35562/developer-big-data-geo-and-web-climate-central http://careers.stackoverflow.com/jobs/35562/developer-big-data-geo-and-web-climate-central
https://github.com/dlh/youtube-dl-parallel * A small utility program to run youtube-dl in parallel.
http://blog.cogneurostats.com/?p=148 https://github.com/dlh/youtube-dl-parallel
* Parallelizing Freesurfer:
http://blog.cogneurostats.com/?p=148
* Bug fixes and man page updates. * Bug fixes and man page updates.

View file

@ -1,6 +1,6 @@
Summary: Shell tool for executing jobs in parallel Summary: Shell tool for executing jobs in parallel
Name: parallel Name: parallel
Version: 20130522 Version: 20130622
Release: 1 Release: 1
License: GPL License: GPL
Group: Productivity/File utilities Group: Productivity/File utilities

View file

@ -24,7 +24,7 @@
use strict; use strict;
use Getopt::Long; use Getopt::Long;
$Global::progname="niceload"; $Global::progname="niceload";
$Global::version = 20130522; $Global::version = 20130622;
Getopt::Long::Configure("bundling","require_order"); Getopt::Long::Configure("bundling","require_order");
get_options_from_array(\@ARGV) || die_usage(); get_options_from_array(\@ARGV) || die_usage();
if($opt::version) { if($opt::version) {

View file

@ -641,7 +641,7 @@ sub get_options_from_array {
sub parse_options { sub parse_options {
# Returns: N/A # Returns: N/A
# Defaults: # Defaults:
$Global::version = 20130606; $Global::version = 20130622;
$Global::progname = 'parallel'; $Global::progname = 'parallel';
$Global::infinity = 2**31; $Global::infinity = 2**31;
$Global::debug = 0; $Global::debug = 0;
@ -756,7 +756,7 @@ sub parse_options {
} }
if($opt::tollef and not $opt::gnu and not $opt::plain) { if($opt::tollef and not $opt::gnu and not $opt::plain) {
# Behave like tollef parallel (from moreutils) # Behave like tollef parallel (from moreutils)
if($Global::version > 20130522) { if($Global::version > 20130622) {
::error("--tollef has been retired. See http://lists.gnu.org/archive/html/parallel/2013-02/msg00018.html\n"); ::error("--tollef has been retired. See http://lists.gnu.org/archive/html/parallel/2013-02/msg00018.html\n");
::wait_and_exit(255); ::wait_and_exit(255);
} }
@ -5311,12 +5311,13 @@ sub xapply_get {
my $empty = 1; my $empty = 1;
for my $fh (@{$self->{'fhs'}}) { for my $fh (@{$self->{'fhs'}}) {
my $arg = read_arg_from_fh($fh); my $arg = read_arg_from_fh($fh);
# Record $arg for recycling at end of file
push @{$self->{'arg_matrix'}{$fh}}, $arg;
if(defined $arg) { if(defined $arg) {
# Record $arg for recycling at end of file
push @{$self->{'arg_matrix'}{$fh}}, $arg;
push @record, $arg; push @record, $arg;
$empty = 0; $empty = 0;
} else { } else {
::debug("EOA");
# End of file: Recycle arguments # End of file: Recycle arguments
push @{$self->{'arg_matrix'}{$fh}}, shift @{$self->{'arg_matrix'}{$fh}}; push @{$self->{'arg_matrix'}{$fh}}, shift @{$self->{'arg_matrix'}{$fh}};
# return last @{$args->{'args'}{$fh}}; # return last @{$args->{'args'}{$fh}};

View file

@ -147,7 +147,7 @@ The replacement string B<{#}> can be changed with B<--seqreplace>.
To understand replacement strings see B<{}>. To understand replacement strings see B<{}>.
=item B<{>I<n>B<}> (beta testing) =item B<{>I<n>B<}>
Argument from input source I<n> or the I<n>'th argument. This Argument from input source I<n> or the I<n>'th argument. This
positional replacement string will be replaced by the input from input positional replacement string will be replaced by the input from input
@ -158,7 +158,7 @@ I<n>'th last argument.
To understand replacement strings see B<{}>. To understand replacement strings see B<{}>.
=item B<{>I<n>.B<}> (beta testing) =item B<{>I<n>.B<}>
Argument from input source I<n> or the I<n>'th argument without Argument from input source I<n> or the I<n>'th argument without
extension. It is a combination of B<{>I<n>B<}> and B<{.}>. extension. It is a combination of B<{>I<n>B<}> and B<{.}>.
@ -171,7 +171,7 @@ extension removed.
To understand positional replacement strings see B<{>I<n>B<}>. To understand positional replacement strings see B<{>I<n>B<}>.
=item B<{>I<n>/B<}> (beta testing) =item B<{>I<n>/B<}>
Basename of argument from input source I<n> or the I<n>'th argument. Basename of argument from input source I<n> or the I<n>'th argument.
It is a combination of B<{>I<n>B<}> and B<{/}>. It is a combination of B<{>I<n>B<}> and B<{/}>.
@ -184,7 +184,7 @@ directory (if any) removed.
To understand positional replacement strings see B<{>I<n>B<}>. To understand positional replacement strings see B<{>I<n>B<}>.
=item B<{>I<n>//B<}> (beta testing) =item B<{>I<n>//B<}>
Dirname of argument from input source I<n> or the I<n>'th argument. Dirname of argument from input source I<n> or the I<n>'th argument.
It is a combination of B<{>I<n>B<}> and B<{//}>. It is a combination of B<{>I<n>B<}> and B<{//}>.
@ -196,7 +196,7 @@ the I<n>'th argument (when used with B<-N>). See B<dirname>(1).
To understand positional replacement strings see B<{>I<n>B<}>. To understand positional replacement strings see B<{>I<n>B<}>.
=item B<{>I<n>/.B<}> (beta testing) =item B<{>I<n>/.B<}>
Basename of argument from input source I<n> or the I<n>'th argument Basename of argument from input source I<n> or the I<n>'th argument
without extension. It is a combination of B<{>I<n>B<}>, B<{/}>, and without extension. It is a combination of B<{>I<n>B<}>, B<{/}>, and
@ -363,7 +363,7 @@ I<size> defaults to 1M.
See B<--pipe> for use of this. See B<--pipe> for use of this.
=item B<--cleanup> (beta testing) =item B<--cleanup>
Remove transferred files. B<--cleanup> will remove the transferred files Remove transferred files. B<--cleanup> will remove the transferred files
on the remote computer after processing is done. on the remote computer after processing is done.
@ -397,7 +397,7 @@ I<regexp> is a Perl Regular Expression:
http://perldoc.perl.org/perlre.html http://perldoc.perl.org/perlre.html
=item B<--ctrlc> (alpha testing) =item B<--ctrlc> (beta testing)
Sends SIGINT to tasks running on remote computers thus killing them. Sends SIGINT to tasks running on remote computers thus killing them.
@ -698,7 +698,7 @@ B<-l 0> is an alias for B<-l 1>.
Implies B<-X> unless B<-m>, B<--xargs>, or B<--pipe> is set. Implies B<-X> unless B<-m>, B<--xargs>, or B<--pipe> is set.
=item B<--load> I<max-load> (beta testing) =item B<--load> I<max-load>
Do not start new jobs on a given computer unless the number of running Do not start new jobs on a given computer unless the number of running
processes on the computer is less than I<max-load>. I<max-load> uses processes on the computer is less than I<max-load>. I<max-load> uses
@ -789,9 +789,9 @@ Instead of printing the output to stdout (standard output) the output
of each job is saved in a file and the filename is then printed. of each job is saved in a file and the filename is then printed.
=item B<--pipe> (beta testing) =item B<--pipe>
=item B<--spreadstdin> (beta testing) =item B<--spreadstdin>
Spread input to jobs on stdin (standard input). Read a block of data Spread input to jobs on stdin (standard input). Read a block of data
from stdin (standard input) and give one block of data as input to one from stdin (standard input) and give one block of data as input to one
@ -840,9 +840,9 @@ B<--progress> on a running GNU B<parallel> process.
See also: B<--eta> See also: B<--eta>
=item B<--max-args>=I<max-args> (beta testing) =item B<--max-args>=I<max-args>
=item B<-n> I<max-args> (beta testing) =item B<-n> I<max-args>
Use at most I<max-args> arguments per command line. Fewer than Use at most I<max-args> arguments per command line. Fewer than
I<max-args> arguments will be used if the size (see the B<-s> option) I<max-args> arguments will be used if the size (see the B<-s> option)
@ -855,9 +855,9 @@ line.
Implies B<-X> unless B<-m> is set. Implies B<-X> unless B<-m> is set.
=item B<--max-replace-args>=I<max-args> (beta testing) =item B<--max-replace-args>=I<max-args>
=item B<-N> I<max-args> (beta testing) =item B<-N> I<max-args>
Use at most I<max-args> arguments per command line. Like B<-n> but Use at most I<max-args> arguments per command line. Like B<-n> but
also makes replacement strings B<{1}> .. B<{>I<max-args>B<}> that also makes replacement strings B<{1}> .. B<{>I<max-args>B<}> that
@ -1065,7 +1065,7 @@ re-use the computers. This is useful if some jobs fail for no apparent
reason (such as network failure). reason (such as network failure).
=item B<--return> I<filename> (beta testing) =item B<--return> I<filename>
Transfer files from remote computers. B<--return> is used with Transfer files from remote computers. B<--return> is used with
B<--sshlogin> when the arguments are files on the remote computers. When B<--sshlogin> when the arguments are files on the remote computers. When
@ -1234,7 +1234,7 @@ Do not use the first line of input (used by GNU B<parallel> itself
when called with B<--shebang>). when called with B<--shebang>).
=item B<--sshdelay> I<secs> (beta testing) =item B<--sshdelay> I<secs>
Delay starting next ssh by I<secs> seconds. GNU B<parallel> will pause Delay starting next ssh by I<secs> seconds. GNU B<parallel> will pause
I<secs> seconds after starting each ssh. I<secs> can be less than 1 I<secs> seconds after starting each ssh. I<secs> can be less than 1
@ -1370,7 +1370,7 @@ different dir for the files. Setting B<--tmpdir> is equivalent to
setting $TMPDIR. setting $TMPDIR.
=item B<--timeout> I<val> (alpha testing) =item B<--timeout> I<val> (beta testing)
Time out for command. If the command runs for longer than I<val> Time out for command. If the command runs for longer than I<val>
seconds it will get killed with SIGTERM, followed by SIGTERM 200 ms seconds it will get killed with SIGTERM, followed by SIGTERM 200 ms
@ -1403,7 +1403,7 @@ Print the job to be run on stderr (standard error).
See also B<-v> and B<-p>. See also B<-v> and B<-p>.
=item B<--transfer> (beta testing) =item B<--transfer>
Transfer files to remote computers. B<--transfer> is used with Transfer files to remote computers. B<--transfer> is used with
B<--sshlogin> when the arguments are files and should be transferred to B<--sshlogin> when the arguments are files and should be transferred to
@ -1515,9 +1515,9 @@ Use B<-v> B<-v> to print the wrapping ssh command when running remotely.
Print the version GNU B<parallel> and exit. Print the version GNU B<parallel> and exit.
=item B<--workdir> I<mydir> (beta testing) =item B<--workdir> I<mydir>
=item B<--wd> I<mydir> (beta testing) =item B<--wd> I<mydir>
Files transferred using B<--transfer> and B<--return> will be relative Files transferred using B<--transfer> and B<--return> will be relative
to I<mydir> on remote computers, and the command will be executed in to I<mydir> on remote computers, and the command will be executed in
@ -1579,7 +1579,7 @@ See also B<-m>.
Exit if the size (see the B<-s> option) is exceeded. Exit if the size (see the B<-s> option) is exceeded.
=item B<--xapply> =item B<--xapply> (alpha testing)
Read multiple input sources like B<xapply>. If multiple input sources Read multiple input sources like B<xapply>. If multiple input sources
are given, one argument will be read from each of the input are given, one argument will be read from each of the input
@ -1593,6 +1593,10 @@ Compare these two:
parallel echo {1} {2} ::: 1 2 3 ::: a b c parallel echo {1} {2} ::: 1 2 3 ::: a b c
parallel --xapply echo {1} {2} ::: 1 2 3 ::: a b c parallel --xapply echo {1} {2} ::: 1 2 3 ::: a b c
Arguments will be recycled if one input source has more arguments than the others:
parallel --xapply echo {1} {2} {3} ::: 1 2 ::: I II III ::: a b c d e f g
See also B<--header>. See also B<--header>.
=back =back

View file

@ -157,8 +157,8 @@ The replacement string @strong{@{#@}} can be changed with @strong{--seqreplace}.
To understand replacement strings see @strong{@{@}}. To understand replacement strings see @strong{@{@}}.
@item @strong{@{}@emph{n}@strong{@}} (beta testing) @item @strong{@{}@emph{n}@strong{@}}
@anchor{@strong{@{}@emph{n}@strong{@}} (beta testing)} @anchor{@strong{@{}@emph{n}@strong{@}}}
Argument from input source @emph{n} or the @emph{n}'th argument. This Argument from input source @emph{n} or the @emph{n}'th argument. This
positional replacement string will be replaced by the input from input positional replacement string will be replaced by the input from input
@ -168,8 +168,8 @@ argument (when used with @strong{-N}). If @emph{n} is negative it refers to the
To understand replacement strings see @strong{@{@}}. To understand replacement strings see @strong{@{@}}.
@item @strong{@{}@emph{n}.@strong{@}} (beta testing) @item @strong{@{}@emph{n}.@strong{@}}
@anchor{@strong{@{}@emph{n}.@strong{@}} (beta testing)} @anchor{@strong{@{}@emph{n}.@strong{@}}}
Argument from input source @emph{n} or the @emph{n}'th argument without Argument from input source @emph{n} or the @emph{n}'th argument without
extension. It is a combination of @strong{@{}@emph{n}@strong{@}} and @strong{@{.@}}. extension. It is a combination of @strong{@{}@emph{n}@strong{@}} and @strong{@{.@}}.
@ -181,8 +181,8 @@ extension removed.
To understand positional replacement strings see @strong{@{}@emph{n}@strong{@}}. To understand positional replacement strings see @strong{@{}@emph{n}@strong{@}}.
@item @strong{@{}@emph{n}/@strong{@}} (beta testing) @item @strong{@{}@emph{n}/@strong{@}}
@anchor{@strong{@{}@emph{n}/@strong{@}} (beta testing)} @anchor{@strong{@{}@emph{n}/@strong{@}}}
Basename of argument from input source @emph{n} or the @emph{n}'th argument. Basename of argument from input source @emph{n} or the @emph{n}'th argument.
It is a combination of @strong{@{}@emph{n}@strong{@}} and @strong{@{/@}}. It is a combination of @strong{@{}@emph{n}@strong{@}} and @strong{@{/@}}.
@ -194,8 +194,8 @@ directory (if any) removed.
To understand positional replacement strings see @strong{@{}@emph{n}@strong{@}}. To understand positional replacement strings see @strong{@{}@emph{n}@strong{@}}.
@item @strong{@{}@emph{n}//@strong{@}} (beta testing) @item @strong{@{}@emph{n}//@strong{@}}
@anchor{@strong{@{}@emph{n}//@strong{@}} (beta testing)} @anchor{@strong{@{}@emph{n}//@strong{@}}}
Dirname of argument from input source @emph{n} or the @emph{n}'th argument. Dirname of argument from input source @emph{n} or the @emph{n}'th argument.
It is a combination of @strong{@{}@emph{n}@strong{@}} and @strong{@{//@}}. It is a combination of @strong{@{}@emph{n}@strong{@}} and @strong{@{//@}}.
@ -206,8 +206,8 @@ the @emph{n}'th argument (when used with @strong{-N}). See @strong{dirname}(1).
To understand positional replacement strings see @strong{@{}@emph{n}@strong{@}}. To understand positional replacement strings see @strong{@{}@emph{n}@strong{@}}.
@item @strong{@{}@emph{n}/.@strong{@}} (beta testing) @item @strong{@{}@emph{n}/.@strong{@}}
@anchor{@strong{@{}@emph{n}/.@strong{@}} (beta testing)} @anchor{@strong{@{}@emph{n}/.@strong{@}}}
Basename of argument from input source @emph{n} or the @emph{n}'th argument Basename of argument from input source @emph{n} or the @emph{n}'th argument
without extension. It is a combination of @strong{@{}@emph{n}@strong{@}}, @strong{@{/@}}, and without extension. It is a combination of @strong{@{}@emph{n}@strong{@}}, @strong{@{/@}}, and
@ -383,8 +383,8 @@ than a single record.
See @strong{--pipe} for use of this. See @strong{--pipe} for use of this.
@item @strong{--cleanup} (beta testing) @item @strong{--cleanup}
@anchor{@strong{--cleanup} (beta testing)} @anchor{@strong{--cleanup}}
Remove transferred files. @strong{--cleanup} will remove the transferred files Remove transferred files. @strong{--cleanup} will remove the transferred files
on the remote computer after processing is done. on the remote computer after processing is done.
@ -420,8 +420,8 @@ separating the columns. The n'th column can be access using
@emph{regexp} is a Perl Regular Expression: @emph{regexp} is a Perl Regular Expression:
http://perldoc.perl.org/perlre.html http://perldoc.perl.org/perlre.html
@item @strong{--ctrlc} (alpha testing) @item @strong{--ctrlc} (beta testing)
@anchor{@strong{--ctrlc} (alpha testing)} @anchor{@strong{--ctrlc} (beta testing)}
Sends SIGINT to tasks running on remote computers thus killing them. Sends SIGINT to tasks running on remote computers thus killing them.
@ -750,8 +750,8 @@ standard specifies @strong{-L} instead.
Implies @strong{-X} unless @strong{-m}, @strong{--xargs}, or @strong{--pipe} is set. Implies @strong{-X} unless @strong{-m}, @strong{--xargs}, or @strong{--pipe} is set.
@item @strong{--load} @emph{max-load} (beta testing) @item @strong{--load} @emph{max-load}
@anchor{@strong{--load} @emph{max-load} (beta testing)} @anchor{@strong{--load} @emph{max-load}}
Do not start new jobs on a given computer unless the number of running Do not start new jobs on a given computer unless the number of running
processes on the computer is less than @emph{max-load}. @emph{max-load} uses processes on the computer is less than @emph{max-load}. @emph{max-load} uses
@ -844,11 +844,11 @@ all the output from one server will be grouped together.
Instead of printing the output to stdout (standard output) the output Instead of printing the output to stdout (standard output) the output
of each job is saved in a file and the filename is then printed. of each job is saved in a file and the filename is then printed.
@item @strong{--pipe} (beta testing) @item @strong{--pipe}
@anchor{@strong{--pipe} (beta testing)} @anchor{@strong{--pipe}}
@item @strong{--spreadstdin} (beta testing) @item @strong{--spreadstdin}
@anchor{@strong{--spreadstdin} (beta testing)} @anchor{@strong{--spreadstdin}}
Spread input to jobs on stdin (standard input). Read a block of data Spread input to jobs on stdin (standard input). Read a block of data
from stdin (standard input) and give one block of data as input to one from stdin (standard input) and give one block of data as input to one
@ -896,11 +896,11 @@ By sending GNU @strong{parallel} SIGUSR2 you can toggle turning on/off
See also: @strong{--eta} See also: @strong{--eta}
@item @strong{--max-args}=@emph{max-args} (beta testing) @item @strong{--max-args}=@emph{max-args}
@anchor{@strong{--max-args}=@emph{max-args} (beta testing)} @anchor{@strong{--max-args}=@emph{max-args}}
@item @strong{-n} @emph{max-args} (beta testing) @item @strong{-n} @emph{max-args}
@anchor{@strong{-n} @emph{max-args} (beta testing)} @anchor{@strong{-n} @emph{max-args}}
Use at most @emph{max-args} arguments per command line. Fewer than Use at most @emph{max-args} arguments per command line. Fewer than
@emph{max-args} arguments will be used if the size (see the @strong{-s} option) @emph{max-args} arguments will be used if the size (see the @strong{-s} option)
@ -912,11 +912,11 @@ line.
Implies @strong{-X} unless @strong{-m} is set. Implies @strong{-X} unless @strong{-m} is set.
@item @strong{--max-replace-args}=@emph{max-args} (beta testing) @item @strong{--max-replace-args}=@emph{max-args}
@anchor{@strong{--max-replace-args}=@emph{max-args} (beta testing)} @anchor{@strong{--max-replace-args}=@emph{max-args}}
@item @strong{-N} @emph{max-args} (beta testing) @item @strong{-N} @emph{max-args}
@anchor{@strong{-N} @emph{max-args} (beta testing)} @anchor{@strong{-N} @emph{max-args}}
Use at most @emph{max-args} arguments per command line. Like @strong{-n} but Use at most @emph{max-args} arguments per command line. Like @strong{-n} but
also makes replacement strings @strong{@{1@}} .. @strong{@{}@emph{max-args}@strong{@}} that also makes replacement strings @strong{@{1@}} .. @strong{@{}@emph{max-args}@strong{@}} that
@ -1139,8 +1139,8 @@ there are fewer than @emph{n} computers in @strong{--sshlogin} GNU @strong{paral
re-use the computers. This is useful if some jobs fail for no apparent re-use the computers. This is useful if some jobs fail for no apparent
reason (such as network failure). reason (such as network failure).
@item @strong{--return} @emph{filename} (beta testing) @item @strong{--return} @emph{filename}
@anchor{@strong{--return} @emph{filename} (beta testing)} @anchor{@strong{--return} @emph{filename}}
Transfer files from remote computers. @strong{--return} is used with Transfer files from remote computers. @strong{--return} is used with
@strong{--sshlogin} when the arguments are files on the remote computers. When @strong{--sshlogin} when the arguments are files on the remote computers. When
@ -1331,8 +1331,8 @@ composed commands for GNU @strong{parallel}.
Do not use the first line of input (used by GNU @strong{parallel} itself Do not use the first line of input (used by GNU @strong{parallel} itself
when called with @strong{--shebang}). when called with @strong{--shebang}).
@item @strong{--sshdelay} @emph{secs} (beta testing) @item @strong{--sshdelay} @emph{secs}
@anchor{@strong{--sshdelay} @emph{secs} (beta testing)} @anchor{@strong{--sshdelay} @emph{secs}}
Delay starting next ssh by @emph{secs} seconds. GNU @strong{parallel} will pause Delay starting next ssh by @emph{secs} seconds. GNU @strong{parallel} will pause
@emph{secs} seconds after starting each ssh. @emph{secs} can be less than 1 @emph{secs} seconds after starting each ssh. @emph{secs} can be less than 1
@ -1473,8 +1473,8 @@ into temporary files in /tmp. By setting @strong{--tmpdir} you can use a
different dir for the files. Setting @strong{--tmpdir} is equivalent to different dir for the files. Setting @strong{--tmpdir} is equivalent to
setting $TMPDIR. setting $TMPDIR.
@item @strong{--timeout} @emph{val} (alpha testing) @item @strong{--timeout} @emph{val} (beta testing)
@anchor{@strong{--timeout} @emph{val} (alpha testing)} @anchor{@strong{--timeout} @emph{val} (beta testing)}
Time out for command. If the command runs for longer than @emph{val} Time out for command. If the command runs for longer than @emph{val}
seconds it will get killed with SIGTERM, followed by SIGTERM 200 ms seconds it will get killed with SIGTERM, followed by SIGTERM 200 ms
@ -1507,8 +1507,8 @@ Print the job to be run on stderr (standard error).
See also @strong{-v} and @strong{-p}. See also @strong{-v} and @strong{-p}.
@item @strong{--transfer} (beta testing) @item @strong{--transfer}
@anchor{@strong{--transfer} (beta testing)} @anchor{@strong{--transfer}}
Transfer files to remote computers. @strong{--transfer} is used with Transfer files to remote computers. @strong{--transfer} is used with
@strong{--sshlogin} when the arguments are files and should be transferred to @strong{--sshlogin} when the arguments are files and should be transferred to
@ -1630,11 +1630,11 @@ Use @strong{-v} @strong{-v} to print the wrapping ssh command when running remot
Print the version GNU @strong{parallel} and exit. Print the version GNU @strong{parallel} and exit.
@item @strong{--workdir} @emph{mydir} (beta testing) @item @strong{--workdir} @emph{mydir}
@anchor{@strong{--workdir} @emph{mydir} (beta testing)} @anchor{@strong{--workdir} @emph{mydir}}
@item @strong{--wd} @emph{mydir} (beta testing) @item @strong{--wd} @emph{mydir}
@anchor{@strong{--wd} @emph{mydir} (beta testing)} @anchor{@strong{--wd} @emph{mydir}}
Files transferred using @strong{--transfer} and @strong{--return} will be relative Files transferred using @strong{--transfer} and @strong{--return} will be relative
to @emph{mydir} on remote computers, and the command will be executed in to @emph{mydir} on remote computers, and the command will be executed in
@ -1695,8 +1695,8 @@ See also @strong{-m}.
Exit if the size (see the @strong{-s} option) is exceeded. Exit if the size (see the @strong{-s} option) is exceeded.
@item @strong{--xapply} @item @strong{--xapply} (alpha testing)
@anchor{@strong{--xapply}} @anchor{@strong{--xapply} (alpha testing)}
Read multiple input sources like @strong{xapply}. If multiple input sources Read multiple input sources like @strong{xapply}. If multiple input sources
are given, one argument will be read from each of the input are given, one argument will be read from each of the input
@ -1712,6 +1712,12 @@ Compare these two:
parallel --xapply echo {1} {2} ::: 1 2 3 ::: a b c parallel --xapply echo {1} {2} ::: 1 2 3 ::: a b c
@end verbatim @end verbatim
Arguments will be recycled if one input source has more arguments than the others:
@verbatim
parallel --xapply echo {1} {2} {3} ::: 1 2 ::: I II III ::: a b c d e f g
@end verbatim
See also @strong{--header}. See also @strong{--header}.
@end table @end table

View file

@ -556,7 +556,7 @@ $Global::Initfile && unlink $Global::Initfile;
exit ($err); exit ($err);
sub parse_options { sub parse_options {
$Global::version = 20130522; $Global::version = 20130622;
$Global::progname = 'sql'; $Global::progname = 'sql';
# This must be done first as this may exec myself # This must be done first as this may exec myself

View file

@ -9,7 +9,7 @@ echo '### bug #38354: -J profile_name should read from `pwd`/profile_name before
echo "### Test --delay" echo "### Test --delay"
seq 9 | /usr/bin/time -f %e parallel -j3 --delay 0.57 true {} 2>&1 | seq 9 | /usr/bin/time -f %e parallel -j3 --delay 0.57 true {} 2>&1 |
perl -ne '$_ > 5 and print "More than 5 secs: OK\n"' perl -ne '$_ > 3.3 and print "More than 3.3 secs: OK\n"'
echo '### test --sshdelay' echo '### test --sshdelay'
stdout /usr/bin/time -f %e parallel -j0 --sshdelay 0.5 -S localhost true ::: 1 2 3 | perl -ne 'print($_ > 1.80 ? "OK\n" : "Not OK\n")' stdout /usr/bin/time -f %e parallel -j0 --sshdelay 0.5 -S localhost true ::: 1 2 3 | perl -ne 'print($_ > 1.80 ? "OK\n" : "Not OK\n")'

View file

@ -1,7 +1,7 @@
### Test if we can deal with output > 4 GB ### Test if we can deal with output > 4 GB
46a318993dfc8e2afd71ff2bc6f605f1 - 46a318993dfc8e2afd71ff2bc6f605f1 -
### Test Force outside the file handle limit, 2009-02-17 Gave fork error ### Test Force outside the file handle limit, 2009-02-17 Gave fork error
parallel: Warning: Only enough filehandles to run 506 jobs in parallel. Raising ulimit -n may help. parallel: Warning: Only enough filehandles to run 507 jobs in parallel. Raising ulimit -n may help.
Start Start
end end
### Test of --retries on unreachable host ### Test of --retries on unreachable host

View file

@ -1,7 +1,7 @@
### bug #38354: -J profile_name should read from `pwd`/profile_name before ~/.parallel/profile_name ### bug #38354: -J profile_name should read from `pwd`/profile_name before ~/.parallel/profile_name
echo from ./local_test_profile echo 1 echo from ./local_test_profile echo 1
### Test --delay ### Test --delay
More than 5 secs: OK More than 3.3 secs: OK
### test --sshdelay ### test --sshdelay
OK OK
### bug #38299: --resume-failed -k ### bug #38299: --resume-failed -k
@ -44,7 +44,7 @@ bug #37694: Empty string argument skipped when using --quote
1 2 1 2
11 1 11 1
12 2 12 2
3 11 3
a_b_c_{4} a_b_c_{4}
a_b_c_d a_b_c_d
{4} {4}

View file

@ -110,7 +110,7 @@ sleep 4
8 12 8 12
9 13 9 13
10 14 10 14
15 1 15
1 5 1 5
2 6 2 6
3 7 3 7
@ -121,7 +121,7 @@ sleep 4
8 12 8 12
9 13 9 13
10 14 10 14
15 1 15
1 5 1 5
2 6 2 6
3 7 3 7
@ -132,7 +132,7 @@ sleep 4
8 12 8 12
9 13 9 13
10 14 10 14
15 1 15
1 5 1 5
2 6 2 6
3 7 3 7
@ -143,7 +143,7 @@ sleep 4
8 12 8 12
9 13 9 13
10 14 10 14
15 1 15
### Test xapply --max-replace-args ### Test xapply --max-replace-args
2 1 0 2 1 0
5 4 3 5 4 3
@ -168,7 +168,7 @@ parallel: Error: Cannot open input file `nonexistent': No such file or directory
8 12 8 12
9 13 9 13
10 14 10 14
15 1 15
### Test -d, :::: ### Test -d, ::::
a1 5b a1 5b
a2 6b a2 6b
@ -217,16 +217,16 @@ echo a echo b
### Quoting if there is a command and 2 arg files of uneven length ### Quoting if there is a command and 2 arg files of uneven length
echo echo\ a echo\ b echo echo\ a echo\ b
echo a echo b echo a echo b
echo a1 echo a1 echo\ b
a1 a1 echo b
### Quoting if there is no command and 2 arg files ### Quoting if there is no command and 2 arg files
echo a echo b echo a echo b
a echo b a echo b
### Quoting if there is no command and 2 arg files of uneven length ### Quoting if there is no command and 2 arg files of uneven length
echo a echo b echo a echo b
a echo b a echo b
echo a1 echo a1 echo b
a1 a1 echo b
### Test multiple -a ### Test multiple -a
echo b a echo b a
b a b a
@ -272,7 +272,7 @@ press CTRL-D or CTRL-C
4 5 4 5
### Test --arg-file-sep with files of different lengths ### Test --arg-file-sep with files of different lengths
1 3 1 3
4 1 4
### Test respect -s ### Test respect -s
echo 1 22 333 echo 1 22 333
1 22 333 1 22 333

View file

@ -1,5 +1,5 @@
### Test -k ### Test -k
parallel: Warning: Only enough filehandles to run 19 jobs in parallel. Raising ulimit -n may help. parallel: Warning: Only enough filehandles to run 20 jobs in parallel. Raising ulimit -n may help.
begin begin
1 1
2 2