X-Git-Url: http://git.shiar.net/barcat.git/blobdiff_plain/42b353c7a02e988fe27f0ec8f39a80e00ea84163..97da4d68eddd9d66e30a73978afe2ad2f08364a7:/barcat?ds=sidebyside diff --git a/barcat b/barcat index 9a5d3e8..144b624 100755 --- a/barcat +++ b/barcat @@ -1,10 +1,9 @@ #!/usr/bin/perl -CA -use 5.018; +use 5.014; use warnings; use utf8; use List::Util qw( min max sum ); use open qw( :std :utf8 ); -use experimental qw( lexical_subs ); our $VERSION = '1.06'; @@ -112,7 +111,8 @@ $opt{'value-length'} = 1 if $opt{unmodified}; $opt{'signal-stat'} //= exists $SIG{INFO} ? 'INFO' : 'QUIT'; $opt{markers} //= '=avg >31.73v <68.27v +50v |0'; $opt{palette} //= $opt{color} && [31, 90, 32]; -$opt{input} = @ARGV && $ARGV[0] =~ m/\A[-0-9]/ ? \@ARGV : undef; +$opt{input} = @ARGV && $ARGV[0] =~ m/\A[-0-9]/ ? \@ARGV : undef + and undef $opt{interval}; my (@lines, @values, @order); @@ -498,7 +498,7 @@ Monitor network latency from prefixed results: Commonly used after counting, for example users on the current server: - users | sed 's/ /\n/g' | sort | uniq -c | barcat + users | tr ' ' '\n' | sort | uniq -c | barcat Letter frequencies in text files: