mirror of
https://git.savannah.gnu.org/git/parallel.git
synced 2024-11-22 05:57:54 +00:00
parallel: retired -g -B -T -U -W -Y
This commit is contained in:
parent
7422375902
commit
dbfb878246
|
@ -137,10 +137,10 @@ https://savannah.gnu.org/news/approve.php?group=parallel
|
|||
|
||||
http://freshmeat.net/projects/parallel/releases/new
|
||||
|
||||
== Update Twitter ==
|
||||
== Update Diaspora Twitter ==
|
||||
|
||||
New version of #GNU Parallel released. See what is new in this release
|
||||
http://nd.gd/2j Watch the intro video http://nd.gd/039
|
||||
http://nd.gd/2j Watch the intro videos http://nd.gd/039
|
||||
|
||||
https://savannah.gnu.org/news/?group=parallel
|
||||
|
||||
|
@ -168,37 +168,46 @@ https://lists.gnu.org/mailman/admindb/parallel
|
|||
|
||||
<<<<<
|
||||
from:tange@gnu.org
|
||||
to:parallel@gnu.org, bug-parallel@gnu.org, info-gnu@gnu.org, bug-directory@gnu.org
|
||||
to:parallel@gnu.org, bug-parallel@gnu.org
|
||||
cc:Sandro Cazzaniga <kharec@mandriva.org>,
|
||||
Tim Cuthbertson <tim3d.junk@gmail.com>, Ludovic Courtès
|
||||
<ludo@gnu.org>, Markus Ammer <mkmm@gmx-topmail.de>, Pavel Nuzhdin
|
||||
<pnzhdin@gmail.com>, Phil Sung <psung@alum.mit.edu>, Michael
|
||||
Shigorin <mike@altlinux.org>, Andrew McFague <amcfague@wgen.net>,
|
||||
Steven M. Christensen <sunfreeware@gmail.com>, Chris Howey
|
||||
<howeyc@gmail.com>, Fethican Coşkuner <fethicanc@gmail.com>,
|
||||
Rogério Brito <rbrito@ime.usp.br>, Koen Vervloesem
|
||||
<koen@vervloesem.eu>, R. Tyler Croy <tyler@monkeypox.org>,
|
||||
Tim Cuthbertson <tim3d.junk@gmail.com>,
|
||||
Steven M. Christensen <sunfreeware@gmail.com>,
|
||||
Ludovic Courtès <ludo@gnu.org>, Markus Ammer <mkmm@gmx-topmail.de>,
|
||||
Pavel Nuzhdin <pnzhdin@gmail.com>, Phil Sung <psung@alum.mit.edu>,
|
||||
Michael Shigorin <mike@altlinux.org>,
|
||||
Andrew McFague <amcfague@wgen.net>,
|
||||
Chris Howey <howeyc@gmail.com>,
|
||||
Fethican Coşkuner <fethicanc@gmail.com>,
|
||||
Rogério Brito <rbrito@ime.usp.br>,
|
||||
Koen Vervloesem <koen@vervloesem.eu>,
|
||||
R. Tyler Croy <tyler@monkeypox.org>,
|
||||
kerick@shiftedbit.net, Christian Faulhammer <fauli@gentoo.org>,
|
||||
Ryoichiro Suzuki <ryoichiro.suzuki@gmail.com>, Jesse Alama
|
||||
<jesse.alama@gmail.com>
|
||||
Ryoichiro Suzuki <ryoichiro.suzuki@gmail.com>,
|
||||
Jesse Alama <jesse.alama@gmail.com>
|
||||
|
||||
Subject: GNU Parallel 20111222 ('Hitchens') released
|
||||
Subject: GNU Parallel 20120122 ('Fhqwhgads') released
|
||||
|
||||
GNU Parallel 20111122 ('Hitchens') has been released. It is
|
||||
GNU Parallel 20120122 ('Fhqwhgads') has been released. It is
|
||||
available for download at: http://ftp.gnu.org/gnu/parallel/
|
||||
|
||||
This is a bugfix release with no new features. Probably a good release
|
||||
for stable long-term use.
|
||||
|
||||
New in this release:
|
||||
|
||||
* --timeout will now kill grandchildren.
|
||||
* Blog post on using GNU Parallel to speed up BLAST queries:
|
||||
http://blog.mckuhn.de/2012/01/embarrassingly-parallel-blast-search.html
|
||||
|
||||
* Interview in Hacker Public Radio.
|
||||
http://hackerpublicradio.org/eps.php?id=0860
|
||||
* Show your support for GNU Parallel. For 20 EUR incl world wide
|
||||
shipping get a GNU Parallel T-shirt+mug+pen+100 postcards. Email
|
||||
your shirt size and address for details to
|
||||
parallel-support@tange.dk.
|
||||
|
||||
* Blog post in Chinese.
|
||||
http://blog.sina.com.cn/s/blog_3f7652740100y0ju.html
|
||||
* Video showing Wake-on-LAN with GNU Parallel.
|
||||
https://www.youtube.com/watch?v=0mB-yIyKFLQ
|
||||
|
||||
* Using GNU Parallel with Solr.
|
||||
http://sujitpal.blogspot.com/2011/12/solr-report-generation-with-python.html
|
||||
|
||||
* First job ad including GNU Parallel:
|
||||
http://seeker.dice.com/jobsearch/servlet/JobSearch?op=101&dockey=xml/7/6/76f858de083a094f74b1a5d3ba53ffc5@endecaindex
|
||||
|
||||
* Bug fixes and man page updates.
|
||||
|
||||
|
|
45
src/parallel
45
src/parallel
|
@ -92,13 +92,13 @@ if($::opt_nonall or $::opt_onall) {
|
|||
join(" ",
|
||||
((defined $::opt_P) ? "-P $::opt_P" : ""),
|
||||
((defined $::opt_u) ? "-u" : ""),
|
||||
((defined $::opt_g) ? "-g" : ""),
|
||||
((defined $::opt_group) ? "-g" : ""),
|
||||
((defined $::opt_D) ? "-D" : ""),
|
||||
);
|
||||
my $suboptions =
|
||||
join(" ",
|
||||
((defined $::opt_u) ? "-u" : ""),
|
||||
((defined $::opt_g) ? "-g" : ""),
|
||||
((defined $::opt_group) ? "-g" : ""),
|
||||
((defined @::opt_v) ? "-vv" : ""),
|
||||
((defined $::opt_D) ? "-D" : ""),
|
||||
((defined $::opt_timeout) ? "--timeout ".$::opt_timeout : ""),
|
||||
|
@ -388,12 +388,14 @@ sub options_hash {
|
|||
"joblog=s" => \$::opt_joblog,
|
||||
"silent" => \$::opt_silent,
|
||||
"keep-order|keeporder|k" => \$::opt_k,
|
||||
"group|g" => \$::opt_g,
|
||||
"group" => \$::opt_group,
|
||||
"g" => \$::opt_retired,
|
||||
"ungroup|u" => \$::opt_u,
|
||||
"null|0" => \$::opt_0,
|
||||
"quote|q" => \$::opt_q,
|
||||
"I=s" => \$::opt_I,
|
||||
"extensionreplace|er|U=s" => \$::opt_U,
|
||||
"extensionreplace|er" => \$::opt_U,
|
||||
"U=s" => \$::opt_retired,
|
||||
"basenamereplace|bnr=s" => \$::opt_basenamereplace,
|
||||
"dirnamereplace|dnr=s" => \$::opt_dirnamereplace,
|
||||
"basenameextensionreplace|bner=s" => \$::opt_basenameextensionreplace,
|
||||
|
@ -419,12 +421,16 @@ sub options_hash {
|
|||
"trc=s" => \@::opt_trc,
|
||||
"transfer" => \$::opt_transfer,
|
||||
"cleanup" => \$::opt_cleanup,
|
||||
"basefile|bf|B=s" => \@::opt_basefile,
|
||||
"workdir|wd|W=s" => \$::opt_workdir,
|
||||
"basefile|bf" => \@::opt_basefile,
|
||||
"B=s" => \$::opt_retired,
|
||||
"workdir|wd=s" => \$::opt_workdir,
|
||||
"W=s" => \$::opt_retired,
|
||||
"tmpdir=s" => \$::opt_tmpdir,
|
||||
"tempdir=s" => \$::opt_tmpdir,
|
||||
"tty|T" => \$::opt_tty,
|
||||
"halt-on-error|halt|H=i" => \$::opt_halt_on_error,
|
||||
"tty" => \$::opt_tty,
|
||||
"T" => \$::opt_retired,
|
||||
"halt-on-error|halt=i" => \$::opt_halt_on_error,
|
||||
"H=i" => \$::opt_retired,
|
||||
"retries=i" => \$::opt_retries,
|
||||
"dry-run|dryrun" => \$::opt_dryrun,
|
||||
"progress" => \$::opt_progress,
|
||||
|
@ -472,8 +478,9 @@ sub options_hash {
|
|||
"fg" => \$::opt_fg,
|
||||
"bg" => \$::opt_bg,
|
||||
"wait" => \$::opt_wait,
|
||||
# Shebang #!/usr/bin/parallel -Yotheroptions
|
||||
"Y|shebang|hashbang" => \$::opt_shebang,
|
||||
# Shebang #!/usr/bin/parallel --shebang
|
||||
"shebang|hashbang" => \$::opt_shebang,
|
||||
"Y" => \$::opt_retired,
|
||||
"skip-first-line" => \$::opt_skip_first_line,
|
||||
);
|
||||
}
|
||||
|
@ -532,12 +539,22 @@ sub parse_options {
|
|||
|
||||
@ARGV=read_options();
|
||||
|
||||
if(defined $::opt_retired) {
|
||||
print STDERR "$Global::progname: -g has been retired. Use --group.\n";
|
||||
print STDERR "$Global::progname: -B has been retired. Use --bf.\n";
|
||||
print STDERR "$Global::progname: -T has been retired. Use --tty.\n";
|
||||
print STDERR "$Global::progname: -U has been retired. Use --er.\n";
|
||||
print STDERR "$Global::progname: -W has been retired. Use --wd.\n";
|
||||
print STDERR "$Global::progname: -Y has been retired. Use --shebang.\n";
|
||||
print STDERR "$Global::progname: -H has been retired. Use --halt.\n";
|
||||
::wait_and_exit(255);
|
||||
}
|
||||
if(defined @::opt_v) { $Global::verbose = $#::opt_v+1; } # Convert -v -v to v=2
|
||||
$Global::debug = (defined $::opt_D);
|
||||
if(defined $::opt_X) { $Global::ContextReplace = 1; }
|
||||
if(defined $::opt_silent) { $Global::verbose = 0; }
|
||||
if(defined $::opt_k) { $Global::keeporder = 1; }
|
||||
if(defined $::opt_g) { $Global::grouped = 1; }
|
||||
if(defined $::opt_group) { $Global::grouped = 1; }
|
||||
if(defined $::opt_u) { $Global::grouped = 0; }
|
||||
if(defined $::opt_0) { $/ = "\0"; }
|
||||
if(defined $::opt_d) { my $e="sprintf \"$::opt_d\""; $/ = eval $e; }
|
||||
|
@ -608,7 +625,7 @@ sub parse_options {
|
|||
if(not defined $::opt_P) {
|
||||
$::opt_P = 1;
|
||||
}
|
||||
if(not defined $::opt_g) {
|
||||
if(not defined $::opt_group) {
|
||||
$Global::grouped = 0;
|
||||
}
|
||||
}
|
||||
|
@ -729,11 +746,9 @@ sub read_options {
|
|||
# Returns:
|
||||
# @ARGV without --options
|
||||
# This must be done first as this may exec myself
|
||||
if(defined $ARGV[0] and ($ARGV[0]=~/^-Y/ or $ARGV[0]=~/^--shebang / or
|
||||
if(defined $ARGV[0] and ($ARGV[0]=~/^--shebang / or
|
||||
$ARGV[0]=~/^--hashbang /)) {
|
||||
# Program is called from #! line in script
|
||||
$ARGV[0]=~s/^-Y( |$)//; # remove -Y if on its own
|
||||
$ARGV[0]=~s/^-Y/-/; # remove -Y if bundled with other options
|
||||
$ARGV[0]=~s/^--shebang *//; # remove --shebang if it is set
|
||||
$ARGV[0]=~s/^--hashbang *//; # remove --hashbang if it is set
|
||||
my $argfile = pop @ARGV;
|
||||
|
|
|
@ -292,12 +292,10 @@ See also: B<:::>.
|
|||
|
||||
=item B<--bf> I<file>
|
||||
|
||||
=item B<-B> I<file> (-B will be retired 20120122)
|
||||
|
||||
I<file> will be transferred to each sshlogin before a jobs is
|
||||
started. It will be removed if B<--cleanup> is active. The file may be
|
||||
a script to run or some common base data needed for the jobs.
|
||||
Multiple B<-B> can be specified to transfer more basefiles. The
|
||||
Multiple B<--bf> can be specified to transfer more basefiles. The
|
||||
I<file> will be transferred the same way as B<--transfer>.
|
||||
|
||||
|
||||
|
@ -458,8 +456,6 @@ B<--gnu> takes precedence.
|
|||
|
||||
=item B<--group>
|
||||
|
||||
=item B<-g> (-g will be retired 20120122)
|
||||
|
||||
Group output. Output from each jobs is grouped together and is only
|
||||
printed when the command is finished. stderr (standard error) first
|
||||
followed by stdout (standard output). This takes some CPU time. In
|
||||
|
@ -482,8 +478,6 @@ Print a summary of the options to GNU B<parallel> and exit.
|
|||
|
||||
=item B<--halt> <0|1|2>
|
||||
|
||||
=item B<-H> <0|1|2> (-H will be retired 20120122)
|
||||
|
||||
=over 3
|
||||
|
||||
=item 0
|
||||
|
@ -1150,8 +1144,6 @@ Can be reversed with B<-v>.
|
|||
|
||||
=item B<--tty>
|
||||
|
||||
=item B<-T> (-T will be retired 20120122)
|
||||
|
||||
Open terminal tty. If GNU B<parallel> is used for starting an
|
||||
interactive program then this option may be needed. It will start only
|
||||
one job at a time (i.e. B<-j1>), not buffer the output (i.e. B<-u>),
|
||||
|
@ -1272,8 +1264,6 @@ faster with B<-u>. Can be reversed with B<--group>.
|
|||
|
||||
=item B<--er> I<replace-str>
|
||||
|
||||
=item B<-U> I<replace-str> (-U will be retired 20120122)
|
||||
|
||||
Use the replacement string I<replace-str> instead of {.} for input line without extension.
|
||||
|
||||
|
||||
|
@ -1308,8 +1298,6 @@ Print the version GNU B<parallel> and exit.
|
|||
|
||||
=item B<--wd> I<mydir>
|
||||
|
||||
=item B<-W> I<mydir> (-W will be retired 20120122)
|
||||
|
||||
Files transferred using B<--transfer> and B<--return> will be relative
|
||||
to I<mydir> on remote computers, and the command will be executed in
|
||||
that dir. The special workdir B<...> will create a workdir in
|
||||
|
@ -1371,8 +1359,6 @@ Compare these two:
|
|||
|
||||
=item B<--hashbang>
|
||||
|
||||
=item B<-Y> (-Y will be retired 20120122)
|
||||
|
||||
GNU B<Parallel> can be called as a shebang (#!) command as the first line of a script. Like this:
|
||||
|
||||
#!/usr/bin/parallel --shebang -r traceroute
|
||||
|
@ -2112,9 +2098,9 @@ same time:
|
|||
|
||||
You can use GNU B<parallel> to start interactive programs like emacs or vi:
|
||||
|
||||
B<cat filelist | parallel -T -X emacs>
|
||||
B<cat filelist | parallel --tty -X emacs>
|
||||
|
||||
B<cat filelist | parallel -T -X vi>
|
||||
B<cat filelist | parallel --tty -X vi>
|
||||
|
||||
If there are more files than will fit on a single command line, the
|
||||
editor will be started again with the remaining files.
|
||||
|
|
|
@ -4,6 +4,14 @@
|
|||
cat <<'EOF' | sed -e s/\$SERVER1/$SERVER1/\;s/\$SERVER2/$SERVER2/ | parallel -j10 -k -L1
|
||||
echo '### Test --timeout';
|
||||
parallel -j0 -k --timeout 1 echo {}\; sleep {}\; echo {} ::: 1.1 2.2 3.3 4.4
|
||||
echo '### Test retired';
|
||||
stdout parallel -B;
|
||||
stdout parallel -g;
|
||||
stdout parallel -H;
|
||||
stdout parallel -T;
|
||||
stdout parallel -U;
|
||||
stdout parallel -W;
|
||||
stdout parallel -Y;
|
||||
EOF
|
||||
|
||||
echo '### Test --shellquote'
|
||||
|
|
|
@ -4,6 +4,28 @@
|
|||
2.2
|
||||
3.3
|
||||
4.4
|
||||
### Test retired
|
||||
parallel: -g has been retired. Use --group.
|
||||
parallel: -B has been retired. Use --bf.
|
||||
parallel: -T has been retired. Use --tty.
|
||||
parallel: -U has been retired. Use --er.
|
||||
parallel: -W has been retired. Use --wd.
|
||||
parallel: -Y has been retired. Use --shebang.
|
||||
parallel: -H has been retired. Use --halt.
|
||||
parallel: -g has been retired. Use --group.
|
||||
parallel: -B has been retired. Use --bf.
|
||||
parallel: -T has been retired. Use --tty.
|
||||
parallel: -U has been retired. Use --er.
|
||||
parallel: -W has been retired. Use --wd.
|
||||
parallel: -Y has been retired. Use --shebang.
|
||||
parallel: -H has been retired. Use --halt.
|
||||
parallel: -g has been retired. Use --group.
|
||||
parallel: -B has been retired. Use --bf.
|
||||
parallel: -T has been retired. Use --tty.
|
||||
parallel: -U has been retired. Use --er.
|
||||
parallel: -W has been retired. Use --wd.
|
||||
parallel: -Y has been retired. Use --shebang.
|
||||
parallel: -H has been retired. Use --halt.
|
||||
### Test --shellquote
|
||||
awk\ -v\ FS=\"\\\",\\\"\"\ \'\{print\ \$1,\ \$3,\ \$4,\ \$5,\ \$9,\ \$14\}\'\ \|\ grep\ -v\ \"\#\"\ \|\ sed\ -e\ \'1d\'\ -e\ \'s/\\\"//g\'\ -e\ \'s/\\/\\/\\//\\t/g\'\ \|\ cut\ -f1-6,11\ \|\ sed\ -e\ \'s/\\/\\//\\t/g\'\ -e\ \'s/\ /\\t/g
|
||||
### Test make .deb package
|
||||
|
|
Loading…
Reference in a new issue