src/utils/qa/findLevel 1.5
1.5 2010/03/13 01:35:07 rhead
Added changes to work with updated tdbQuery that recognizes multiple release tags (like beta,public).
Index: src/utils/qa/findLevel
===================================================================
RCS file: /projects/compbio/cvsroot/kent/src/utils/qa/findLevel,v
retrieving revision 1.4
retrieving revision 1.5
diff -b -B -U 4 -r1.4 -r1.5
--- src/utils/qa/findLevel 11 Mar 2010 00:10:36 -0000 1.4
+++ src/utils/qa/findLevel 13 Mar 2010 01:35:07 -0000 1.5
@@ -22,9 +22,9 @@
db=""
tableName=""
currDir=""
-error=""
+error="no"
# get arguments or print usage
if [ $# -ne 2 ]
then
@@ -87,34 +87,34 @@
fi
###########################################
# find the trackDb.ra entry (using tdbQuery)
-
+# the tdbQuery default is -release=alpha
echo " * trackDb:"
-all=`tdbQuery "select track,priority,visibility,release,filePos from \
+alpha=`tdbQuery "select track,release,priority,visibility,filePos from \
$db where track='$tableName'" 2> /dev/null` || error=yes
-strict=`tdbQuery -strict "select track,priority,visibility,release,filePos from \
+beta=`tdbQuery -release=beta "select track,release,priority,visibility,filePos from \
$db where track='$tableName'" 2> /dev/null` || error=yes
-alpha=`tdbQuery -alpha "select track,priority,visibility,release,filePos from \
+public=`tdbQuery -release=public "select track,release,priority,visibility,filePos from \
$db where track='$tableName'" 2> /dev/null` || error=yes
-# always print "all"; only print strict or alpha if they differ from all
-echo -e "$all\n"
-if [ "$all" != "$strict" ]
+# always print "alpha"; only print beta or public if they differ from alpha
+echo -e "$alpha\n"
+if [ "$alpha" != "$beta" ]
then
- echo -e "$strict\n"
+ echo -e "$beta\n"
fi
-if [ "$alpha" != "$all" ] && [ "$alpha" != "$strict" ]
+if [ "$alpha" != "$public" ] && [ "$beta" != "$public" ]
then
- echo -e "$alpha\n"
+ echo -e "$public\n"
fi
-# if tdbQuery is only giving errors, $all will be empty and nothing printed
+# if tdbQuery is only giving errors, variables will be empty and nothing printed
if [ "$error" = "yes" ]
then
- echo -e "\nERROR: tdbQuery returned only errors\n" >&2
+ echo -e "\nERROR: tdbQuery returned errors\n" >&2
exit 1
fi
exit 0