4 # Builds an index from UMD Freeze 3.0 of the Bos Taurus (cow) genome.
40 ChrY-contigs.SHOTGUN_ONLY"
42 CHRS_TO_INDEX=$BASE_CHRS
46 if ! wget --version >/dev/null 2>/dev/null ; then
47 if ! curl --version >/dev/null 2>/dev/null ; then
48 echo "Please install wget or curl somewhere in your PATH"
51 curl -o `basename $1` $1
59 BOWTIE_BUILD_EXE=./bowtie-build
60 if [ ! -x "$BOWTIE_BUILD_EXE" ] ; then
61 if ! which bowtie-build ; then
62 echo "Could not find bowtie-build in current directory or in PATH"
65 BOWTIE_BUILD_EXE=`which bowtie-build`
69 FTP_BASE=ftp://ftp.cbcb.umd.edu/pub/data/Bos_taurus/Bos_taurus_UMD_3.0
73 for c in $CHRS_TO_INDEX ; do
74 if [ ! -f ${c}.fa ] ; then
76 get ${FTP_BASE}/$F || (echo "Error getting $F" && exit 1)
77 gunzip $F || (echo "Error unzipping $F" && exit 1)
79 [ -n "$INPUTS" ] && INPUTS=$INPUTS,${c}.fa
80 [ -z "$INPUTS" ] && INPUTS=${c}.fa
83 CMD="$BOWTIE_BUILD_EXE $* $INPUTS $OUTPUT"
86 echo "$OUTPUT index built; you may remove fasta files"
88 echo "Index building failed; see error message"