From cca8ac474cb4980eb40d55c2d457cf0e260e6083 Mon Sep 17 00:00:00 2001 From: renewiegandt Date: Sun, 6 Jan 2019 15:34:38 +0100 Subject: [PATCH] Added check for \t at the end of lines in BED-file --- bin/1.2_filter_motifs/compareBed.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/bin/1.2_filter_motifs/compareBed.sh b/bin/1.2_filter_motifs/compareBed.sh index e1ac62f..99423f7 100644 --- a/bin/1.2_filter_motifs/compareBed.sh +++ b/bin/1.2_filter_motifs/compareBed.sh @@ -89,7 +89,7 @@ case $key in esac done -# stores unknown selected parameters for error report +# stores unknown selected parameters for error report count=${#wrong[@]} if [ $count -gt 0 ] then @@ -178,7 +178,7 @@ then fi #default path of the scripts merge.R and maxScore.R is the same path as compareBed.sh has -# the `echo $0 | sed 's/\/[^\/]*$/\//g'` command extracts the path from $0, where the command itself is stored +# the `echo $0 | sed 's/\/[^\/]*$/\//g'` command extracts the path from $0, where the command itself is stored if [ $pa == false ] then path=`echo $0 | sed 's/\/[^\/]*$/\//g'` @@ -198,6 +198,7 @@ if [ -d "$motifs" ] then for i in "$motifs"/*.bed do + sed -i 's/[ \t]*$//' $i if [ $help == true ] then help=false @@ -272,7 +273,7 @@ do done fi -#The output of the last iteration of the subtract loop is written to pass2Tr.bed +#The output of the last iteration of the subtract loop is written to pass2Tr.bed if [ $help == false ] then cat "$workdir"/pass1FaHelp.bed > "$workdir"/pass2Tr.bed