git.shiar.nl
/
barcat.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
version 1.10 marking stable log support
[barcat.git]
/
barcat
diff --git
a/barcat
b/barcat
index a129091c4418f59b511f801236e6094e351bddd5..2b1a7148175b08cc06fbd48fe680597cd64e56f1 100755
(executable)
--- a/
barcat
+++ b/
barcat
@@
-6,7
+6,7
@@
use List::Util qw( min max sum );
use open qw( :std :utf8 );
use re '/msx';
use open qw( :std :utf8 );
use re '/msx';
-our $VERSION = '1.
09
';
+our $VERSION = '1.
10
';
my %opt;
if (@ARGV) {
my %opt;
if (@ARGV) {
@@
-152,9
+152,9
@@
$opt{report} //= join('',
'${count#} values',
'${lines#; $_ = $_ != @order && " over $_ lines"}',
sprintf('${count: (%s)}', join ', ',
'${count#} values',
'${lines#; $_ = $_ != @order && " over $_ lines"}',
sprintf('${count: (%s)}', join ', ',
- '${
min
; color(31)} min',
+ '${
0v
; color(31)} min',
'${avg; $opt{reformat} or $_ = sprintf "%0.2f", $_; color(36)} avg',
'${avg; $opt{reformat} or $_ = sprintf "%0.2f", $_; color(36)} avg',
- '${
max
; color(32)} max',
+ '${
100v
; color(32)} max',
),
);
$opt{palette} //= $opt{color} && [31, 90, 32];
),
);
$opt{palette} //= $opt{color} && [31, 90, 32];
@@
-399,10
+399,6
@@
sub show_stat {
if (@order) {
$vars{partsum} = sum(0, grep {length} @values[$linemin .. $linemax])
if $linemin <= $linemax and ($opt{hidemin} or $opt{hidemax});
if (@order) {
$vars{partsum} = sum(0, grep {length} @values[$linemin .. $linemax])
if $linemin <= $linemax and ($opt{hidemin} or $opt{hidemax});
- %vars = (%vars,
- min => $order[-1],
- max => $order[0],
- );
}
say varfmt($opt{report}, \%vars);
return 1;
}
say varfmt($opt{report}, \%vars);
return 1;