BUG: potentialFoam/cylinder: indexing into non-existing patch in parallel
[OpenFOAM-2.0.x.git] / bin / tools / replaceAllShellSun
blobd5a0d8db9952fa878bd1289bdf89b4b981f6311b
1 #!/usr/xpg4/bin/sh
3 # Replace all shell script headers with
4 if [ $# -ne 1 -o ! -d "$1" ]
5 then
6 echo "Usage: ${0##*/} <dir>"
7 echo ""
8 echo "Replaces all occurrences of #!/bin/sh with #!/usr/xpg4/bin/sh inside a directory tree."
9 exit 1
12 #- note that below does not work since {} does not get replaced
13 #find $1 -type f -exec /usr/xpg4/bin/sh -c "grep '^#\!/bin/sh' {} >/dev/null && echo {} && mv {} {}_bak && sed -e 's@^#\!/bin/sh@#\!/usr/xpg4/bin/sh@' {}_bak > {}" ';'
15 find $1 -exec $WM_PROJECT_DIR/bin/tools/inlineReplace '^#\!/bin/sh' '#\!/usr/xpg4/bin/sh' {} \; -print
17 # ----------------------------------------------------------------- end-of-file