8715d83d38d8bb18adfdd9ce05771b4cede85407
angie
  Fri Dec 5 09:52:07 2014 -0800
Moved some hgTables code that had been copied into a couple differentplaces into a new lib module, cartTrackDb.  hgGenome/import.c has code
that is fairly similar but that also needs to filter out custom tracks
that were generated by hgGenome.

diff --git src/hg/lib/wikiTrack.c src/hg/lib/wikiTrack.c
index 563b6ab..de8e71d 100644
--- src/hg/lib/wikiTrack.c
+++ src/hg/lib/wikiTrack.c
@@ -1049,15 +1049,33 @@
 	}
     }
 return editor;
 } 
 
 char *wikiUrl(struct wikiTrack *item)
 /* construct a URL to the wiki page for the specified item
 	free the returned string when done with it.  */
 {
 char *siteUrl = cfgOptionDefault(CFG_WIKI_URL, NULL);
 struct dyString *itemUrl = dyStringNew(64);
 dyStringPrintf(itemUrl, "%s/index.php/%s TARGET=_blank", siteUrl,
         item->descriptionKey);
 return dyStringCannibalize(&itemUrl);
 }
+
+struct trackDb *wikiTrackDb()
+/* Create & return a trackDb for the wiki track. */
+{
+struct trackDb *tdb;
+AllocVar(tdb);
+tdb->track = WIKI_TRACK_TABLE;
+tdb->table = WIKI_TRACK_TABLE;
+tdb->shortLabel = WIKI_TRACK_LABEL;
+tdb->longLabel = WIKI_TRACK_LONGLABEL;
+tdb->visibility = tvFull;
+tdb->priority = WIKI_TRACK_PRIORITY;
+tdb->html = hFileContentsOrWarning(hHelpFile(tdb->track));
+tdb->type = "none";
+tdb->grp = "map";
+tdb->canPack = FALSE;
+return tdb;
+}