From: Vivien Delmon Date: Wed, 29 Feb 2012 12:13:01 +0000 (+0100) Subject: Replace tabulations with space in pts_to_landmarks script X-Git-Tag: v1.3.0~82^2^2~1 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=c38abb6437739d95d361b214c1265b4e337a3645;p=clitk.git Replace tabulations with space in pts_to_landmarks script --- diff --git a/scripts/pts_to_landmarks.sh b/scripts/pts_to_landmarks.sh index e93cbe4..5f02900 100755 --- a/scripts/pts_to_landmarks.sh +++ b/scripts/pts_to_landmarks.sh @@ -17,14 +17,16 @@ fi to_append=`mktemp` to_prepend=`mktemp` +pts_file_spaced=`mktemp` for i in $(seq 0 $((`cat $1 | wc -l` - 1))); do - echo 0' '0 >> $to_append + echo "0 0" >> $to_append echo $i >> $to_prepend done echo "LANDMARKS1" > $2 -paste -d ' ' $to_prepend $1 $to_append >> $2 +cat $1 | sed -e 's/\s/ /g' >> $pts_file_spaced +paste -d ' ' $to_prepend $pts_file_spaced $to_append >> $2 -rm $to_append $to_prepend +rm $to_append $to_prepend $pts_file_spaced