src/utils/bigBedToBed/bigBedToBed.c 1.7

1.7 2009/09/08 19:50:24 kent
Adding udcDir to the command line as an option.
Index: src/utils/bigBedToBed/bigBedToBed.c
===================================================================
RCS file: /projects/compbio/cvsroot/kent/src/utils/bigBedToBed/bigBedToBed.c,v
retrieving revision 1.6
retrieving revision 1.7
diff -b -B -U 4 -r1.6 -r1.7
--- src/utils/bigBedToBed/bigBedToBed.c	14 Aug 2009 20:52:35 -0000	1.6
+++ src/utils/bigBedToBed/bigBedToBed.c	8 Sep 2009 19:50:24 -0000	1.7
@@ -3,8 +3,9 @@
 #include "linefile.h"
 #include "hash.h"
 #include "options.h"
 #include "localmem.h"
+#include "udc.h"
 #include "bigBed.h"
 
 static char const rcsid[] = "$Id$";
 
@@ -24,16 +25,18 @@
   "   -chrom=chr1 - if set restrict output to given chromosome\n"
   "   -start=N - if set, restrict output to only that over start\n"
   "   -end=N - if set, restict output to only that under end\n"
   "   -maxItems=N - if set, restrict output to first N items\n"
+  "   -udcDir=/dir/to/cache - place to put cache for remote bigBed/bigWigs\n"
   );
 }
 
 static struct optionSpec options[] = {
    {"chrom", OPTION_STRING},
    {"start", OPTION_INT},
    {"end", OPTION_INT},
    {"maxItems", OPTION_INT},
+   {"udcDir", OPTION_STRING},
    {NULL, 0},
 };
 
 void bigBedToBed(char *inFile, char *outFile)
@@ -86,8 +89,9 @@
 clChrom = optionVal("chrom", clChrom);
 clStart = optionInt("start", clStart);
 clEnd = optionInt("end", clEnd);
 maxItems = optionInt("maxItems", maxItems);
+udcSetDefaultDir(optionVal("udcDir", udcDefaultDir()));
 if (argc != 3)
     usage();
 bigBedToBed(argv[1], argv[2]);
 return 0;