7a68602b325c40864c6937bc5803c4afd606bc9d
hiram
  Thu Jul 21 20:19:43 2022 -0700
customize the track table for viral genomes refs #29545

diff --git src/hg/makeDb/doc/asmHubs/trackData.pl src/hg/makeDb/doc/asmHubs/trackData.pl
index 64ea1ba..2b0a2f6 100755
--- src/hg/makeDb/doc/asmHubs/trackData.pl
+++ src/hg/makeDb/doc/asmHubs/trackData.pl
@@ -203,31 +203,31 @@
 
 ##############################################################################
 ### start the table output
 ##############################################################################
 sub startTable() {
 
 # coordinate the order of these column headings with the @trackList listed above
 
 print '<table class="sortable" border="1">
 <thead><tr><th>count</th>
   <th>common name<br>link&nbsp;to&nbsp;genome&nbsp;browser</th>
 ';
   print '<th class="sorttable_numeric">ncbiRefSeq</th>
 ' if ("viral" ne $asmHubName);
 
-print "  <th class=\"sorttable_numeric\">ncbiGene</th>\n" if ($testOutput);
+print "  <th class=\"sorttable_numeric\">ncbiGene</th>\n" if ($testOutput || ("viral" eq $asmHubName));
 
 print '  <th class="sorttable_numeric">xenoRefGene</th>
   <th class="sorttable_numeric">augustus<br>genes</th>
   <th class="sorttable_numeric">Ensembl<br>genes</th>
 ' if ("viral" ne $asmHubName);
 
 print '  <th class="sorttable_numeric">gc5 base</th>
 ';
 
 if ($testOutput) {
   print "  <th class=\"sorttable_numeric\">AGP<br>gap</th>\n";
   print "  <th class=\"sorttable_numeric\">all<br>gaps</th>\n";
 } else {
   print "  <th class=\"sorttable_numeric\">gaps</th>\n";
 }
@@ -347,31 +347,31 @@
 #     14
 # my @trackList = qw(ncbiRefSeq xenoRefGene augustus ensGene gc5Base gap allGaps assembly rmsk simpleRepeat windowMasker gapOverlap tandemDups cpgIslandExtUnmasked cpgIslandExt);
 #                       0            1         2        3       4      5      6
 #      7      8           9               10
 # my @trackList = qw(ncbiRefSeq xenoRefGene augustus ensGene gc5Base allGaps assembly rmsk simpleRepeat windowMasker cpgIslandExtUnmasked);
     splice @trackList, 11, 0, "cpgIslandExt";
     splice @trackList, 10, 0, "tandemDups";
     splice @trackList, 10, 0, "gapOverlap";
     splice @trackList, 5, 0, "gap";
   }
   if ("viral" eq $asmHubName) {
     splice @trackList, 3, 1;
     splice @trackList, 2, 1;
     splice @trackList, 1, 1;
   }
-  if ($testOutput) {  # add extra columns during 'test' output
+  if ($testOutput || ("viral" eq $asmHubName)) {  # add extra columns during 'test' output
     splice @trackList, 1, 0, "ncbiGene";
   }
   if ("viral" eq $asmHubName) {
     splice @trackList, 0, 1;
   }
   foreach my $asmId (@orderList) {
     my $gcPrefix = "GCx";
     my $asmAcc = "asmAcc";
     my $asmName = "asmName";
     my $accessionId = "GCx_098765432.1";
     my $accessionDir = "";
     my $configRa = "n/a";
     my $tracksCounted = 0;
     my $buildDir = "/hive/data/genomes/asmHubs/refseqBuild/$accessionDir/$asmId";
     my $asmReport="$buildDir/download/${asmId}_assembly_report.txt";