From 1350f3a0d3dddf9efa00029166cf060467585650 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Fri, 12 Feb 2016 01:43:08 +0000 Subject: [PATCH] commitid: Pass $bestwhat to do_some_best (nfc) --- commitid.scad.pl | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/commitid.scad.pl b/commitid.scad.pl index 0af0115..68bd4ce 100755 --- a/commitid.scad.pl +++ b/commitid.scad.pl @@ -565,7 +565,8 @@ sub do_git () { } sub do_some_best ($$) { - my ($modname, $formre) = @_; + my ($bestwhat, $formre) = @_; + my $modname = "Best$bestwhat"; my $fullmodname = "Commitid_${modname}_2D"; my @argl = qw(max_sz margin=Commitid_pixelsz()); p "module $fullmodname(".argl_formal(@argl).") {\n"; @@ -628,8 +629,8 @@ sub do_git_best () { # (decreasing), and then by number of lines (increasing) and # try each one both ways round. - do_some_best('BestCount', 'Small|Full') if $do_git =~ m/c/; - do_some_best('BestObjid', 'Git|Full') if $do_git =~ m/o/; + do_some_best('Count', 'Small|Full') if $do_git =~ m/c/; + do_some_best('Objid', 'Git|Full') if $do_git =~ m/o/; } while (@ARGV) { -- 2.30.2