Commit cebb64d4 authored by mac's avatar mac

Fixed xvcg path, fixed for new tables

parent 6dba8ba9
......@@ -78,40 +78,15 @@ foreach $tbl ( @tbls ) {
}
}
my %sortlist = ("nodes",2,"interfaces",10,"ip_list",14,"node_types",4,
"wires",13,"reserved",16,"node_id",1,"ifc",11,"ip",15,
"mac",12,"type",3,"proc",5,"speed",6,"ifcs",7,"ram",8,
"hd",9,"eid",17,"delta_proj",18,"delta_inst",20,"deltas",21,
"delta_compat",22,"disk_images",19,"image_id",23,"delta_id",24,
"img_desc",25,"os",26,"ver",27,"extras",28,"free_space",29,
"free_space_type",30,"time_install_exp",51,
"time_install_node",52,"time_boot_exp",53,"time_boot_node",54,
"img_path",35,"delta_name",36,"delta_desc",37,"delta_path",38,
"quick_clean",39,"trusted",40,"users",41,"grp_memb",45,
"groups",42,"proj_memb",46,"projects",43,"proj_grps",47,
"experiments",44,"log",48,"login",49,"ssh_host_keys",50,
"outlets",31,"partitions",55
);
sub mysort {
if(!defined $sortlist{"\L$a"}) {
print "No sort key for \L$a.\n";
} elsif(!defined $sortlist{"\L$b"}) {
print "No sort key for \L$b.\n";
} else {
return $sortlist{"\L$a"} <=> $sortlist{"\L$b"};
}
return "\L$a" cmp "\L$b";
}
foreach $tbl ( sort mysort @tablelist) {
foreach $tbl ( sort @tablelist) {
print TMP " node: { title: \"$tbl\" }\n";
}
foreach $col ( sort keys %tablecols) {
@tables= sort mysort split('\.',$tablecols{$col});
foreach $tbl (sort mysort @tables) {
@tables= sort split('\.',$tablecols{$col});
foreach $tbl (sort @tables) {
if (@tables < 2 ||
$tbl=~/^delta_|nodes|log|exper|res|out|part|int/i ) {
$tbl=~/^delta_|proj_|dela|rel|nodes|log|exper|res|out|part|int/i ) {
print TMP " edge: { sourcename: \"$col\" ".
"targetname: \"$tbl\" }\n";
} else {
......@@ -123,6 +98,6 @@ foreach $col ( sort keys %tablecols) {
print TMP "}\n";
close TMP;
system("/home/reid/X11R6/bin/xvcg -silent $filename");
system("/usr/local/bin/xvcg -silent $filename");
exec "/bin/rm $filename";
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