83aa49897ba111a554ff5b92659c868ca47ead0b
hiram
  Tue Jan 3 17:16:01 2023 -0800
correct use of new and improved rmToTrackHub.pl script no redmine

diff --git src/hg/utils/automation/asmHubRepeatMasker.sh src/hg/utils/automation/asmHubRepeatMasker.sh
index 3f021fa..4678efe 100755
--- src/hg/utils/automation/asmHubRepeatMasker.sh
+++ src/hg/utils/automation/asmHubRepeatMasker.sh
@@ -30,38 +30,38 @@
 # assume this file name pattern
 export faAlign=`echo "${rmOutFile}" | sed -e 's/sorted.fa.out/fa.align/; s/.gz//;'`
 export RepeatMaskerPath="/hive/data/staging/data/RepeatMasker221107"
 
 if [ -d "${destDir}" ]; then
   cd "${destDir}"
 
   # might already be gzipped
   if [ ! -s "${faAlign}" ]; then
      faAlign="${faAlign}.gz"
   fi
   # align file only exists when RM has been run locally, not for NCBI version
   # it is OK if it is missing, can do this anyway without it
   if [ -s "${faAlign}" ]; then
     printf "# using faAlign file: %s\n" "${faAlign}" 1>&2
-    printf "$RepeatMaskerPath/util/rmToTrackHub.pl -sizes \"${chrSizes}\" -genome \"${asmId}\" -hubname \"${asmId}\" -out \"${rmOutFile}\" -align \"${faAlign}\"\n" 1>&2
-    $RepeatMaskerPath/util/rmToTrackHub.pl -sizes "${chrSizes}" -genome "${asmId}" -hubname "${asmId}" -out "${rmOutFile}" -align "${faAlign}"
+    printf "time $RepeatMaskerPath/util/rmToTrackHub.pl -sizes \"${chrSizes}\" -genome \"${asmId}\" -hubname \"${asmId}\" -out \"${rmOutFile}\" -align \"${faAlign}\"\n" 1>&2
+    time $RepeatMaskerPath/util/rmToTrackHub.pl -sizes "${chrSizes}" -genome "${asmId}" -hubname "${asmId}" -out "${rmOutFile}" -align "${faAlign}"
     # in place same file sort using the -o output option
     sort -k1,1 -k2,2n -o "${asmId}.fa.align.tsv" "${asmId}.fa.align.tsv" &
   else
     printf "# there is no faAlign file\n" 1>&2
-    printf "$RepeatMaskerPath/util/rmToTrackHub.pl -sizes \"${chrSizes}\" -genome \"${asmId}\" -hubname \"${asmId}\" -out \"${rmOutFile}\"\n" 1>&2
-    $RepeatMaskerPath/util/rmToTrackHub.pl -sizes "${chrSizes}" -genome "${asmId}" -hubname "${asmId}" -out "${rmOutFile}"
+    printf "time $RepeatMaskerPath/util/rmToTrackHub.pl -sizes \"${chrSizes}\" -genome \"${asmId}\" -hubname \"${asmId}\" -out \"${rmOutFile}\"\n" 1>&2
+    time $RepeatMaskerPath/util/rmToTrackHub.pl -sizes "${chrSizes}" -genome "${asmId}" -hubname "${asmId}" -out "${rmOutFile}"
   fi
   sort -k1,1 -k2,2n -o "${asmId}.sorted.fa.join.tsv" "${asmId}.sorted.fa.join.tsv" &
   wait
   printf "bedToBigBed -tab -as=$HOME/kent/src/hg/lib/bigRmskBed.as -type=bed9+5
     \"${asmId}.sorted.fa.join.tsv\" \"${chrSizes}\"
       \"${asmId}.rmsk.bb\" &\n" 1>&2
   bedToBigBed -tab -as=$HOME/kent/src/hg/lib/bigRmskBed.as -type=bed9+5 \
     "${asmId}.sorted.fa.join.tsv" "${chrSizes}" \
       "${asmId}.rmsk.bb" &
   if [ -s "${asmId}.fa.align.tsv" ]; then
     printf "bedToBigBed -tab -as=$HOME/kent/src/hg/lib/bigRmskAlignBed.as
       -type=bed3+14 \"${asmId}.fa.align.tsv\" \"${chrSizes}\"
         \"${asmId}.rmsk.align.bb\" &\n" 1>&2
     bedToBigBed -tab -as=$HOME/kent/src/hg/lib/bigRmskAlignBed.as \
       -type=bed3+14 "${asmId}.fa.align.tsv" "${chrSizes}" \