mirror of
https://git.savannah.gnu.org/git/parallel.git
synced 2024-11-25 15:37:56 +00:00
parallel: Indention.
This commit is contained in:
parent
81a8a116b7
commit
2c587e4055
17
src/parallel
17
src/parallel
|
@ -343,7 +343,7 @@ sub spreadstdin {
|
|||
my $one_time_through;
|
||||
my $blocksize = $opt::blocksize;
|
||||
my $in = *STDIN;
|
||||
piperead: while(1) {
|
||||
while(1) {
|
||||
my $anything_written = 0;
|
||||
if(not read($in,substr($buf,length $buf,0),$blocksize)) {
|
||||
# End-of-file
|
||||
|
@ -351,7 +351,6 @@ sub spreadstdin {
|
|||
# Force the while-loop once if everything was read by header reading
|
||||
$one_time_through++ and last;
|
||||
}
|
||||
|
||||
if($opt::r) {
|
||||
# Remove empty lines
|
||||
$buf=~s/^\s*\n//gm;
|
||||
|
@ -4733,15 +4732,6 @@ sub populate {
|
|||
# max line length is reached
|
||||
# Returns: N/A
|
||||
my $self = shift;
|
||||
# if($opt::pipe) {
|
||||
# # --pipe => Do no read any args
|
||||
# $self->push([Arg->new("")]);
|
||||
# return;
|
||||
# }
|
||||
# if($opt::roundrobin) {
|
||||
# $self->push([Arg->new("")]);
|
||||
# return;
|
||||
# }
|
||||
my $next_arg;
|
||||
while (not $self->{'arg_queue'}->empty()) {
|
||||
$next_arg = $self->{'arg_queue'}->get();
|
||||
|
@ -5102,9 +5092,6 @@ sub replace_placeholders {
|
|||
my $quote = shift;
|
||||
my $context_replace = $self->{'context_replace'};
|
||||
my $replaced;
|
||||
|
||||
# print ::my_dump($self);
|
||||
|
||||
if($self->{'context_replace'}) {
|
||||
$replaced = $self->context_replace_placeholders($target,$quote);
|
||||
} else {
|
||||
|
@ -5158,7 +5145,7 @@ sub context_replace_placeholders {
|
|||
$word{$1} ||= 1;
|
||||
}
|
||||
if(not %word) {
|
||||
# The line did no contain any replacementstrings => return unchanged
|
||||
# The line did no contain any replacement strings => return unchanged
|
||||
return $target;
|
||||
}
|
||||
# For each word: Generate the replacement string for that word.
|
||||
|
|
Loading…
Reference in a new issue