Commit 3f1d56ac authored by Russ Fish's avatar Russ Fish

Add a separate tmcc cache file for the new SWAPPER= field of the

tmcc creator query.
parent d5b41592
......@@ -166,7 +166,7 @@ sub docreator()
if (! @tmccresults);
#
# There should be just one string. Ignore anything else.
# There should be one string for the creator of the experiment...
#
if ($tmccresults[0] =~ /^CREATOR=([-\w]*)/) {
$creator = $1;
......@@ -174,8 +174,19 @@ sub docreator()
else {
fatal("Bad creator line: $tmccresults[0]");
}
system("echo '$creator' > ". TMCREATOR());
#
# ... and another string for the user who swapped it in.
#
if ($tmccresults[0] =~ / SWAPPER=([-\w]*)/) {
$swapper = $1;
}
else {
fatal("Bad swapper line: $tmccresults[0]");
}
system("echo '$swapper' > ". TMSWAPPER());
return 0;
}
......@@ -29,7 +29,8 @@ use Exporter;
CONFDIR TMDELAY TMJAILNAME TMSIMRC TMCC
TMNICKNAME TMSTARTUPCMD FINDIF
TMROUTECONFIG TMLINKDELAY TMDELMAP TMTOPOMAP
TMGATEDCONFIG TMSYNCSERVER TMKEYHASH TMNODEID TMEVENTKEY TMCREATOR
TMGATEDCONFIG TMSYNCSERVER TMKEYHASH TMNODEID TMEVENTKEY
TMCREATOR TMSWAPPER
);
# Must come after package declaration!
......@@ -213,6 +214,7 @@ sub TMNODEID() { CONFDIR() . "/nodeid";}
sub TMROLE() { CONFDIR() . "/role";}
sub TMSIMRC() { CONFDIR() . "/rc.simulator";}
sub TMCREATOR() { CONFDIR() . "/creator";}
sub TMSWAPPER() { CONFDIR() . "/swapper";}
#
# This is a debugging thing for my home network.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment