X-Git-Url: http://dxcluster.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=cmd%2Fshow%2Fversion.pl;h=5707504a190705138cbdfe91cd289e203cf7c172;hb=f6d0b05b25a61cb6d3aa671b7a8f5d4a69817b1c;hp=36d4464b1d724735e2f03add01f46b44c53a06bd;hpb=99da9d68a4fee5b30fa90b679a9e015add2b75c9;p=spider.git diff --git a/cmd/show/version.pl b/cmd/show/version.pl index 36d4464b..5707504a 100644 --- a/cmd/show/version.pl +++ b/cmd/show/version.pl @@ -3,12 +3,29 @@ # # Copyright (c) 1998 Dirk Koopman G1TLH # -# $Id$ +# # +my ($self, $line) = @_; my @out; +my @in = map {uc} split /\s+/, $line; + +if ($self->priv > 5 && @in) { +# $DB::single=1; + + my $q = $in[0] eq 'ALL' ? '.*' : join('|', @in); + my @n = sort {$a->call cmp $b->call} grep {$_->call =~ /^(?:$q)/} Route::Node::get_all(); + push @out, " Node Version Build PC9X via PC92"; + foreach my $n (@n) { + push @out, sprintf " %-10s %5d %5s %3s %3s", $n->call, $n->version, $n->build, yesno($n->do_pc9x), yesno($n->via_pc92); + } + push @out, ' ' . scalar @n . " Nodes found"; +} else { + my ($year) = (gmtime($main::systime))[5]; + $year += 1900; + push @out, "DXSpider v$main::version (build $main::build git: $main::gitbranch/$main::gitversion) using perl $^V on \u$^O"; + push @out, "Copyright (c) 1998-$year Dirk Koopman G1TLH"; +} -push @out, "DX Spider Cluster version $main::version (build $main::build) on \u$^O"; -push @out, "Copyright (c) 1998-2002 Dirk Koopman G1TLH"; return (1, @out);