testshortsortcoordinate.sh 413 B

12345678910111213141516171819202122
  1. #! /bin/bash
  2. SCRIPTDIR=`dirname "${BASH_SOURCE[0]}"`
  3. pushd ${SCRIPTDIR}
  4. SCRIPTDIR=`pwd`
  5. popd
  6. source ${SCRIPTDIR}/sorttestshort.sh
  7. sorttestshort | ../src/bamsort SO=coordinate | ../src/bamchecksort
  8. # copy pipe return status array
  9. PIPESTAT=( ${PIPESTATUS[*]} )
  10. if [ ${PIPESTAT[0]} -ne 0 ] ; then
  11. echo 'bamsort failed'
  12. exit 1
  13. elif [ ${PIPESTAT[1]} -ne 0 ] ; then
  14. echo 'bamchecksort failed'
  15. exit 1
  16. fi
  17. exit 0