From b2378e259cec955cfd9700cd0cac7ea5908f09ce Mon Sep 17 00:00:00 2001 From: Juan RP Date: Tue, 14 Oct 2008 19:22:05 +0200 Subject: [PATCH] Fix replace-interpreter.sh to use doble quotes in sed. --HG-- extra : convert_revision : 9159fb23ddb11d4980276064f4d7aebad1927ad9 --- helper-templates/replace-interpreter.sh | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/helper-templates/replace-interpreter.sh b/helper-templates/replace-interpreter.sh index e90a2960928..1ad975f91ea 100644 --- a/helper-templates/replace-interpreter.sh +++ b/helper-templates/replace-interpreter.sh @@ -37,11 +37,12 @@ replace_interpreter() ;; esac - if [ -f $file ]; then - $sed_cmd -e '1s|^#![[:space:]]*\$orsb|#!\$trpath|' \ - $file > $file.in && $mv_cmd $file.in $file && \ - echo "=> Transformed $lang script: $file." + if [ -f $wrksrc/$file ]; then + $sed_cmd -e "1s|^#![[:space:]]*${orsb}|#!${trpath}|" \ + $wrksrc/$file > $wrksrc/$file.in && \ + $mv_cmd $wrksrc/$file.in $wrksrc/$file && \ + echo "=> Transformed $lang script: ${file##$wrksrc}." else - echo "=> Ignoring unexistent $lang script: $file." + echo "=> Ignoring unexistent $lang script: ${file##$wrksrc}." fi }