bug#24929: comm enhancement proposal: --print-summary --quiet
From:
Bernhard Voelker
Subject:
bug#24929: comm enhancement proposal: --print-summary --quiet
Date:
Mon, 14 Nov 2016 11:30:03 +0100
User-agent:
Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0
On 11/12/2016 12:24 AM, 積丹尼 Dan Jacobson wrote:
> Please add a comm --print-summary and --quiet, so we wouldn't have to write
> $ comm FILE1 FILE2|perl -nwe '
> /^\t+/;
> $h{ length $& || 0 }++;
>
> END {
> @L = ( "Lines in 1st ", "Lines in 2nd ", "Lines in both" );
> printf "%s: %5d\n", $L[$_], $h{$_} for sort keys %h;
> }
> '
> Lines in 1st : 601
> Lines in 2nd : 437
> Lines in both: 2417
This sounds like a domain of diffstat(1), doesn't it?
Have a nice day,
Berny