diff falco-call.sh @ 58:e7de191375e6 draft

Uploaded
author stef
date Thu, 08 Jan 2015 06:18:04 -0500
parents b4e2b4efae61
children 73eda23fb8fd
line wrap: on
line diff
--- a/falco-call.sh	Mon Jan 05 04:55:17 2015 -0500
+++ b/falco-call.sh	Thu Jan 08 06:18:04 2015 -0500
@@ -4,12 +4,10 @@
 echo "Started FALCO calling"
 
 ## ----------
-## Variables setup
+## Variables setup ($1 contains the bash config file path)
 ## ----------
 source $1
 
-bam_base=`echo $bam_name | sed 's#.bam$##' - ` 
-
 ## ----------
 ## make sure all is ok
 ## ----------
@@ -22,20 +20,24 @@
 ## ----------
 ## set params
 ## ----------
-if [[ $filter_file != 'None' && $filter_file != '' ]] # Galaxy default somehow is "None"
+if [[ $filter_file != 'None' && $filter_file != '' ]] # Galaxy default is "None" for some reason
 then 
 	FILTER_PARAM=" --filter "$filter_file
 else
 	FILTER_PARAM=""
 fi
 
-if [[ $manifest_file != 'None' && $manifest_file != 'None' ]] # Galaxy default is "None"
+if [[ $manifest_file != 'None' && $manifest_file != 'None' ]] # Galaxy default is "None" for some reason
 then 
 	MANIFEST_PARAM=" --manifest "$manifest_file
 else
 	MANIFEST_PARAM=""
 fi
 
+## name of file in galaxy not always set so will use a user-set job_name instead
+#bam_base=`echo $bam_name | sed 's#.bam$##' - ` 
+bam_base=$job_name
+
 ## ----------
 ## Status / debug
 ## ----------
@@ -62,11 +64,11 @@
 ## ----------
 ## running analysis
 ## ----------
-echo "Starting variant calling"
+echo "[INFO] Starting variant calling"
 CALL_STRING="$TOOLDIR/falco/bin/falco --bam $bam_file --output $bam_base --ref $REF_FILE $FILTER_PARAM $MANIFEST_PARAM"
 echo "[INFO] "$CALL_STRING
 perl $CALL_STRING
-echo "...done with variant calling"
+echo "[INFO] done with variant calling"
 
 
 ## ----------
@@ -113,4 +115,4 @@
 
 ## ----------
 echo "END falco sh"
-exit 0
\ No newline at end of file
+exit 0