]> Creatis software - clitk.git/commitdiff
Fixed script for my mac
authorSimon Rit <simon.rit@creatis.insa-lyon.fr>
Fri, 7 Jun 2013 15:08:08 +0000 (17:08 +0200)
committerSimon Rit <simon.rit@creatis.insa-lyon.fr>
Fri, 7 Jun 2013 15:08:08 +0000 (17:08 +0200)
make_new_tool.sh

index f2b5484bcdc1949bf49cd4954cabf8ea7d8b8f89..29ca0eea8ee98be87a60bd0de199eba9bf9c9cc8 100644 (file)
@@ -10,7 +10,12 @@ find tools -name "clitkFooImage*" |
 while read i
 do
     cp $i ${i/FooImage/$1}
-    sed -i "s/FooImage/$1/ig" ${i/FooImage/$1}
+    if test "$(uname)" = "Darwin"
+    then
+        sed -i "" "s/FooImage/$1/ig" ${i/FooImage/$1}
+    else
+        sed -i "s/FooImage/$1/ig" ${i/FooImage/$1}
+    fi
 done
 echo "Done!"
 echo "Don't forget to add your new tool to the various CMakeLists.txt files."