From: minima Date: Sun, 14 Oct 2001 10:56:11 +0000 (+0000) Subject: add shortform sh/st like disply to sh/user like ak1a X-Git-Tag: R_1_49~43 X-Git-Url: http://dxcluster.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=a63885de419cf7ae4c10fa10e0107121e237e214;p=spider.git add shortform sh/st like disply to sh/user like ak1a --- diff --git a/Changes b/Changes index 0a515c1e..39905708 100644 --- a/Changes +++ b/Changes @@ -1,3 +1,6 @@ +14Oct01======================================================================= +1. Add the shortform SH/ST like display to sh/user to make it more +AK1A compatible (G0RDI+G4PDQ pace). 12Oct01======================================================================= 1. make del nnn delete messages again (fix system Aliases file) 2. substr the subject so that the dup works for stuff coming back via AK1A diff --git a/cmd/show/users.pl b/cmd/show/users.pl index 46d641ed..d197727b 100644 --- a/cmd/show/users.pl +++ b/cmd/show/users.pl @@ -9,34 +9,48 @@ my ($self, $line) = @_; my @list = map { uc } split /\s+/, $line; # list of callsigns of nodes my @out; -my $node = $main::routeroot; -push @out, "Callsigns connected to $main::mycall"; -my $call; -my $i = 0; -my @l; -my @val = sort $node->users; -foreach $call (@val) { - if (@list) { - next if !grep $call eq $_, @list; - } - if ($i >= 5) { - push @out, sprintf "%-12s %-12s %-12s %-12s %-12s %-12s", @l; - @l = (); - $i = 0; +if (@list) { + foreach my $call (sort @list) { + my $uref = DXUser->get_current($call); + if ($uref) { + my $name = $uref->name || '?'; + my $qth = $uref->qth || '?'; + my $qra = $uref->qra || ''; + my $route = ''; + if (my $rref = Route::get($call)) { + $route = '(at ' . join(',', $rref->parents) . ')'; + } + push @out, "$call $route $name $qth $qra", + } else { + push @out, $self->msg('usernf', $call); + } } - my $uref = Route::User::get($call); - my $s = $call; - if ($uref) { - $s = sprintf "(%s)", $call unless $uref->here; - } else { - $s = "$call?"; +} else { + my $node = $main::routeroot; + push @out, "Callsigns connected to $main::mycall"; + my $call; + my $i = 0; + my @l; + my @val = sort $node->users; + foreach $call (@val) { + if ($i >= 5) { + push @out, sprintf "%-12s %-12s %-12s %-12s %-12s %-12s", @l; + @l = (); + $i = 0; + } + my $uref = Route::User::get($call); + my $s = $call; + if ($uref) { + $s = sprintf "(%s)", $call unless $uref->here; + } else { + $s = "$call?"; + } + push @l, $s; + $i++; } - push @l, $s; - $i++; + push @out, sprintf "%-12s %-12s %-12s %-12s %-12s %-12s", @l; } -push @out, sprintf "%-12s %-12s %-12s %-12s %-12s %-12s", @l; - return (1, @out);