line |
true |
false |
branch |
48
|
36 |
151 |
if ($line =~ /^--- (.*)/) { } |
|
36 |
115 |
elsif ($line =~ /^\+\+\+ (.*)/) { } |
|
37 |
78 |
elsif ($line =~ /^\@@ -(\d+)(?:,(\d+))? \+\d+(?:,\d+)? \@@/) { } |
59
|
3 |
34 |
if $file_a ne $file_b |
64
|
34 |
88 |
if (not defined $line or $line =~ /^[^ +\\-]/) |
70
|
15 |
19 |
defined $2 ? : |
79
|
6 |
28 |
if defined $line |
103
|
40 |
3 |
unless $summary =~ /^(?:fixup|squash)! (.*)/ |
105
|
0 |
3 |
if ($prefix =~ /^(?:(?:fixup|squash)! ){2}/) |
109
|
0 |
3 |
if (@matches > 1) { } |
|
0 |
3 |
elsif (@matches == 0) { } |
|
3 |
0 |
elsif (@matches == 1) { } |
126
|
0 |
34 |
if (grep {not defined $_;} $hunk, $blame, $summary_for, $strict) |
131
|
15 |
19 |
if ($args->{'strict'} == $CONTEXT) { } |
134
|
3 |
12 |
if (@topic_targets > 1) |
145
|
4 |
30 |
if ($strict and $upstream_is_blamed) { } |
|
0 |
30 |
elsif (@topic_targets > 1) { } |
|
3 |
27 |
elsif (@topic_targets == 0) { } |
146
|
0 |
4 |
if $verbose |
149
|
0 |
0 |
if $verbose |
152
|
0 |
3 |
if $verbose |
155
|
0 |
27 |
if ($verbose) |
175
|
0 |
15 |
if grep {not defined $_;} $hunk, $blame, $summary_for |
178
|
15 |
0 |
wantarray ? : |
192
|
0 |
22 |
if (grep {not defined $_;} $hunk, $blame, $summary_for, $strict) |
203
|
17 |
39 |
if (startswith($line, '-')) { } |
|
18 |
21 |
elsif (startswith($line, '+')) { } |
208
|
17 |
1 |
if ($di > 0 and defined $$blame{$bi - 1}) |
211
|
5 |
13 |
if (defined $blame->{$bi}) |
222
|
14 |
4 |
if ($is_surrounded or $strict < $SURROUNDED and $is_adjacent) |
231
|
22 |
0 |
wantarray ? : |
247
|
38 |
22 |
if ($first eq '-' or $first eq ' ') |
262
|
0 |
0 |
if (grep {not defined $_;} $fh, $hunk, $summary_for, $blame, $blame_indexes) |
270
|
0 |
0 |
defined $blame->{$bi} ? : |
272
|
0 |
0 |
defined $sha ? : |
274
|
0 |
0 |
if (startswith($line_r, '+')) |
278
|
0 |
0 |
if (defined $sha and not defined $summary_for->{$sha}) |
284
|
0 |
0 |
if (defined $blame->{$bi} and not startswith($line_r, '+')) |
310
|
1 |
33 |
if ($hunk->{'count'} == 0) |
320
|
0 |
33 |
unless open my $fh, '-|', @cmd |
322
|
54 |
486 |
if ($line =~ /^([0-9a-f]{40}) \d+ (\d+)/) |
325
|
54 |
486 |
if (startswith($line, "\t")) |
326
|
3 |
51 |
if (defined $alias_for->{$sha}) |
332
|
0 |
33 |
unless close $fh |
339
|
0 |
34 |
unless open my $fh, '-|', @cmd |
341
|
0 |
34 |
unless close $fh |
342
|
0 |
34 |
wantarray ? : |
347
|
0 |
22 |
unless open my $fh, '|-', 'git apply --unidiff-zero --cached -' |
356
|
0 |
22 |
unless close $fh |
357
|
0 |
22 |
unless system('git', 'commit', "--fixup=$sha") == 0 |
362
|
0 |
34 |
unless open my $fh, '-|', 'git status --porcelain' |
365
|
0 |
39 |
if ($line =~ /^[^?! ]/) |
370
|
0 |
34 |
unless close $fh |
380
|
0 |
34 |
if (grep {not defined $_;} $hunks, $blame_for, $summary_for, $strict) |
387
|
0 |
34 |
if ($verbose > 1) |
402
|
7 |
27 |
unless $sha |
418
|
11 |
22 |
if @ordered >= $nsha |
421
|
23 |
5 |
if $_->{'file'} eq $tgt->{'file'} |
|
22 |
1 |
if (grep {$_->{'start'} == $tgt->{'start'} if $_->{'file'} eq $tgt->{'file'};} @{$sha_hunks;}) |
437
|
0 |
34 |
unless &GetOptions('h', \$help, 'help', \$man, 'version', \$show_version, 'verbose|v+', \$verbose, 'strict|s=i', \$strict, 'context|c=i', \$num_context_lines) |
445
|
0 |
34 |
if ($help) |
449
|
0 |
34 |
if ($show_version) |
453
|
0 |
34 |
if ($man) |
457
|
0 |
34 |
unless @ARGV == 1 |
460
|
0 |
34 |
unless $? == 0 |
462
|
0 |
34 |
if ($num_context_lines < 0) |
466
|
0 |
34 |
if ($strict < 0) { } |
|
0 |
49 |
elsif ($strict > 0 and $num_context_lines == 0) { } |
475
|
0 |
34 |
unless $? == 0 |
476
|
0 |
34 |
unless chdir $toplevel |
478
|
0 |
34 |
if (is_index_dirty()) |