@@-
-chomp($hostname= `uname -n`); $? and die 'uname $?';
-($hostname)=(gethostbyname $hostname) or die "hostname $hostname ?";
+chomp($nodename= `uname -n`); $? and die 'uname $?';
+($hostname)=(gethostbyname $nodename) or die "hostname $nodename ?";
+
+$xbindir= '/usr/bin/X11';
chomp($s= `uname`); $? and die "platform $?";
if ($s =~ m/^Linux$/) {
chomp($_= `uname -r`); $? and die "platform $?";
m/^\d+\.\d+/ or die "$_ ?";
$platform= "SunOS$&";
+ $xbindir= '/usr/openwin/bin';
} else {
die "$s ?";
}
$ncipher= $hostname =~ m/\.ncipher\.com$/ ? 'cam' :
$hostname =~ m/\.ncipherusa\.com$/ ? 'bos' :
0;
+
PATH=$PATH:$HOME/personal/linux-i386/crypto/scripts
@@;@@#
PATH=$PATH:/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/sbin:/usr/sbin
-PATH=$PATH:/opt/bin:/usr/bin/X11
+PATH=$PATH:/opt/bin:@@$xbindir@@
export PATH
xlsclients | egrep \
'[^ ]* xload -geometry [^ ]* -title '"'xload - $hostname'" \
>/dev/null && exit 0
-xload -geometry 120x120+302+0 -title "xload - $hostname"
+xload -geometry 120x120+@@
+
+@hostlist= ($ncipher eq 'bos' ? qw(viking dover pell arrakis) :
+ $ncipher eq 'cam' ? qw(jura) :
+ qw(davenant anarres));
+for ($i=0; $i<@hostlist; $i++) { last if $hostlist[$i] eq $nodename; }
+if ($i>=@hostlist) {
+ print STDERR "!! nodename $nodename not in $ncipher list @hostlist\n";
+ $i=-2;
+}
+
+302+141*$i;
+
+@@+0 -title "xload - $hostname"
if ($l =~ m/\@\@(.|\n)/) {
($to,$op,$esc,$l) = ($`,$1,$&,$');
add_text($to);
- if ($op =~ m/[-< \$?]/) {
+ if ($op =~ m/[-< \$?\n]/) {
$substr.= $esc if @oplist;
push @oplist, $op;
add_perl($op) if $op =~ m/[\$]/;
INSTALLDIR= $(HOME)/bin
-TARGETS= with-lock-ex
+TARGETS= with-lock-ex close3onwards
CPPFLAGS= $(OPTIONS)
CFLAGS= $(OPTIMISE)
.configs/checkconfig +x
.configs/chiarks +x
.configs/configure +x
+.configs/rxprofile +x
.configs/startemacs +x
.configs/x11start +x
.configs/xbiffs +x
platform @@$platform@@
+nodename @@$nodename@@
hostname @@$hostname@@
ncipher @@$ncipher@@