[hg] galaxy 2673: POSIXize/Bournize updateucsc.sh.sample
details: http://www.bx.psu.edu/hg/galaxy/rev/ce8c57840343 changeset: 2673:ce8c57840343 user: Nate Coraor <nate@bx.psu.edu> date: Thu Sep 10 17:31:05 2009 -0400 description: POSIXize/Bournize updateucsc.sh.sample 1 file(s) affected in this change: cron/updateucsc.sh.sample diffs (57 lines): diff -r d3fe789e3931 -r ce8c57840343 cron/updateucsc.sh.sample --- a/cron/updateucsc.sh.sample Thu Sep 10 14:52:38 2009 -0400 +++ b/cron/updateucsc.sh.sample Thu Sep 10 17:31:05 2009 -0400 @@ -6,7 +6,8 @@ # Edit this line to refer to galaxy's path: GALAXY=/galaxy/path -export PYTHONPATH=${GALAXY}/lib +PYTHONPATH=${GALAXY}/lib +export PYTHONPATH # setup directories echo "Creating required directories." @@ -32,7 +33,11 @@ python ${GALAXY}/cron/parse_builds.py > ${GALAXY}/tool-data/shared/ucsc/new/builds.txt if [ $? -eq 0 ] then - cp -uf ${GALAXY}/tool-data/shared/ucsc/new/builds.txt ${GALAXY}/tool-data/shared/ucsc/builds.txt + diff ${GALAXY}/tool-data/shared/ucsc/new/builds.txt ${GALAXY}/tool-data/shared/ucsc/builds.txt > /dev/null 2>&1 + if [ $? -ne 0 ] + then + cp -f ${GALAXY}/tool-data/shared/ucsc/new/builds.txt ${GALAXY}/tool-data/shared/ucsc/builds.txt + fi else echo "Failed to update builds.txt" >&2 fi @@ -42,7 +47,11 @@ python ${GALAXY}/cron/parse_builds_3_sites.py > ${GALAXY}/tool-data/shared/ucsc/new/ucsc_build_sites.txt if [ $? -eq 0 ] then - cp -uf ${GALAXY}/tool-data/shared/ucsc/new/ucsc_build_sites.txt ${GALAXY}/tool-data/shared/ucsc/ucsc_build_sites.txt + diff ${GALAXY}/tool-data/shared/ucsc/new/ucsc_build_sites.txt ${GALAXY}/tool-data/shared/ucsc/ucsc_build_sites.txt > /dev/null 2>&1 + if [ $? -ne 0 ] + then + cp -f ${GALAXY}/tool-data/shared/ucsc/new/ucsc_build_sites.txt ${GALAXY}/tool-data/shared/ucsc/ucsc_build_sites.txt + fi else echo "Failed to update builds.txt" >&2 fi @@ -52,7 +61,16 @@ python ${GALAXY}/cron/build_chrom_db.py ${GALAXY}/tool-data/shared/ucsc/chrom/new/ ${GALAXY}/tool-data/shared/ucsc/builds.txt if [ $? -eq 0 ] then - cp -uf ${GALAXY}/tool-data/shared/ucsc/chrom/new/*.len ${GALAXY}/tool-data/shared/ucsc/chrom/ + for src in ${GALAXY}/tool-data/shared/ucsc/chrom/new/*.len + do + dst=${GALAXY}/tool-data/shared/ucsc/chrom/`basename $src` + diff $src $dst > /dev/null 2>&1 + if [ $? -ne 0 ] + then + echo "cp -f $src $dst" + cp -f $src $dst + fi + done else echo "Failed to update chromInfo tables." >&2 fi
participants (1)
-
Nate Coraor