projects
/
spider.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add uref for call in edu
[spider.git]
/
cmd
/
show
/
node.pl
diff --git
a/cmd/show/node.pl
b/cmd/show/node.pl
index 76372cb5a318c6467a8c4f34bbe3d622407e69c0..063e2e4288942785e29e909b6158723d79caaa10 100644
(file)
--- a/
cmd/show/node.pl
+++ b/
cmd/show/node.pl
@@
-16,30
+16,31
@@
my ($self, $line) = @_;
return (1, $self->msg('e5')) unless $self->priv >= 1;
my ($self, $line) = @_;
return (1, $self->msg('e5')) unless $self->priv >= 1;
-
-use DB_File;
+return (1, $self->msg('storable')) unless $DXUser::v3;
my @call = map {uc $_} split /\s+/, $line;
my @out;
my $count;
# search thru the user for nodes
my @call = map {uc $_} split /\s+/, $line;
my @out;
my $count;
# search thru the user for nodes
-
unless (@call
) {
-
- my ($action, $key, $data);
+
if ($call[0] eq 'ALL'
) {
+ shift @call;
+ my ($action, $key, $data)
= (0,0,0)
;
for ($action = DXUser::R_FIRST, $count = 0; !$DXUser::dbm->seq($key, $data, $action); $action = DXUser::R_NEXT) {
for ($action = DXUser::R_FIRST, $count = 0; !$DXUser::dbm->seq($key, $data, $action); $action = DXUser::R_NEXT) {
- if ($data =~ m{
sort => '[ACRSX]'
}) {
+ if ($data =~ m{
\01[ACRSX]\0\0\0\04sort
}) {
push @call, $key;
++$count;
}
}
push @call, $key;
++$count;
}
}
+} elsif (@call == 0) {
+ @call = map {$_->call} DXChannel::get_all_nodes();
}
my $call;
foreach $call (@call) {
}
my $call;
foreach $call (@call) {
- my $clref =
DXCluster->get_exac
t($call);
+ my $clref =
Route::Node::ge
t($call);
my $uref = DXUser->get_current($call);
my $uref = DXUser->get_current($call);
- my ($sort, $ver);
+ my ($sort, $ver
, $build
);
my $pcall = sprintf "%-11s", $call;
push @out, $self->msg('snode1') unless @out > 0;
my $pcall = sprintf "%-11s", $call;
push @out, $self->msg('snode1') unless @out > 0;
@@
-56,16
+57,20
@@
foreach $call (@call) {
push @out, $self->msg('snode3', $call);
next;
}
push @out, $self->msg('snode3', $call);
next;
}
+ $ver = "";
+ $build = "";
if ($call eq $main::mycall) {
$sort = "Spider";
$ver = $main::version;
} else {
if ($call eq $main::mycall) {
$sort = "Spider";
$ver = $main::version;
} else {
- $ver = $clref->pcversion if $clref && $clref->pcversion;
+ $ver = $clref->version if $clref && $clref->version;
+ $ver = $uref->version if $ver && $uref->version;
}
my ($major, $minor, $subs) = unpack("AAA*", $ver) if $ver;
if ($uref->is_spider) {
}
my ($major, $minor, $subs) = unpack("AAA*", $ver) if $ver;
if ($uref->is_spider) {
- push @out, $self->msg('snode2', $pcall, $sort, "$ver ");
+ $build = "build: " . $uref->build if $uref->build;
+ push @out, $self->msg('snode2', $pcall, $sort, "$ver $build");
} else {
push @out, $self->msg('snode2', $pcall, $sort, $ver ? "$major\-$minor.$subs" : " ");
}
} else {
push @out, $self->msg('snode2', $pcall, $sort, $ver ? "$major\-$minor.$subs" : " ");
}