From 8574c41491a95ddddaa282e463f992ff342e42c1 Mon Sep 17 00:00:00 2001 From: rswindell <> Date: Fri, 22 Jun 2001 02:44:06 +0000 Subject: [PATCH] Example node listing module. --- exec/nodelist.js | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 exec/nodelist.js diff --git a/exec/nodelist.js b/exec/nodelist.js new file mode 100644 index 0000000000..2c15e043d6 --- /dev/null +++ b/exec/nodelist.js @@ -0,0 +1,14 @@ +// nodelist.js + +load("nodedefs.js"); + +for(n=0;n<system.node_list.length;n++) { + printf("Node %2d ",n+1); + if(system.node_list[n].status==NODE_INUSE) { + printf("%s ",system.node_list[n].useron_name); + printf(NodeAction[system.node_list[n].action],system.node_list[n].aux); + } else + printf(NodeStatus[system.node_list[n].status],system.node_list[n].aux); + + printf("\r\n"); +} \ No newline at end of file -- GitLab