add sh/cmd_cache
authorDirk Koopman <djk@tobit.co.uk>
Mon, 2 Jul 2007 14:14:29 +0000 (15:14 +0100)
committerDirk Koopman <djk@tobit.co.uk>
Mon, 2 Jul 2007 14:14:29 +0000 (15:14 +0100)
Changes
cmd/Commands_en.hlp
cmd/show/cmd_cache.pl [new file with mode: 0644]
perl/Version.pm

diff --git a/Changes b/Changes
index 8c03986485c21d1fd06e6444648158650f9d3405..1e630cef519aea516021b8c0af3ee44f67f2d6c6 100644 (file)
--- a/Changes
+++ b/Changes
@@ -1,3 +1,7 @@
+02Jul07=======================================================================
+1. Add a new command to show the contents of the cmd_cache. This allows those
+people whom develop their own commands to see which version they are using.
+It is called show/cmd_cache (or sh/cmd for short).
 29Jun07=======================================================================
 1. If a node is set/isolated then make sure that a) pc9x is not advertised
 and b) pc9x is ignored.
index b1fdb80e26a3ef82e1abd801d7b2ce7da62cdcee..66f6db9b8fe27df9cb7bf9bf073ccb206a050f7c 100644 (file)
@@ -915,7 +915,8 @@ will automatially be picked up by the cluster program. Sometimes it
 can get confused if you are doing a lot of moving commands about or
 delete a command in the local_cmd tree and want to use the normal one
 again. Execute this command to reset everything back to the state it
-was just after a cluster restart.
+was just after a cluster restart. To see what is in the command cache
+see SHOW/CMD_CACHE.
 
 === 9^LOAD/FORWARD^Reload the msg forwarding routing table
 Reload the /spider/msg/forward.pl file if you have changed it
@@ -1863,6 +1864,15 @@ occurred whilst you were away. SHOW/CHAT on its own will show data for
 all groups. If you use a group name then it will show only chat for
 that group.
 
+=== 9^SHOW/CMD_CACHE^Show the real source path of commands
+It is possible in DXSpider to define local versions of commands.
+Sometimes one forgets that one has these. This command will show you
+the source path where the node is getting each one of its commands.
+
+If you find a local command that you don't want then then simply
+delete it, run LOAD/CMD_CACHE to clear out the command cache and
+try again. You will now be using the standard version.
+
 === 0^SHOW/CONFIGURATION [<node>]^Show all the nodes and users visible
 This command allows you to see all the users that can be seen
 and the nodes to which they are connected.
diff --git a/cmd/show/cmd_cache.pl b/cmd/show/cmd_cache.pl
new file mode 100644 (file)
index 0000000..bd26c7d
--- /dev/null
@@ -0,0 +1,20 @@
+#
+# show the contents and paths of any commands in the cmd_cache
+#
+# This will tell you whether you are using the version of the command
+# that you think you are...
+#
+# Copyright (c) 2007 Dirk Koopman G1TLH
+#
+
+my $self = shift;
+return (1, $self->msg('e5')) if $self->priv < 9;
+
+my @out = sprintf "%-20s %s", "Command", "Path";
+for (sort keys %cmd_cache) {
+       my $v = $cmd_cache{$_};
+       $v =~ s|,|/|g;
+       push @out, sprintf "%-20s %s", $_, "$v.pl";
+}
+
+return (1, @out);
index 68f113ea87e4944bce4b6747368cd3ab6e202ecd..9b594c33d2a957920961d3e176a164d2d74b4c7b 100644 (file)
@@ -11,6 +11,6 @@ use vars qw($version $subversion $build);
 
 $version = '1.54';
 $subversion = '0';
-$build = '96';
+$build = '97';
 
 1;