Skip to content

Commit 2a132b2

Browse files
committed
Fix python vs python3
1 parent 477b989 commit 2a132b2

1 file changed

Lines changed: 11 additions & 1 deletion

File tree

versionRules/makeFoamVersionHeader.py

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,14 @@
1-
#! /usr/bin/env python
1+
#!/bin/sh
2+
""":"
3+
if command -v python >/dev/null 2>&1; then
4+
exec python "$0" "$@"
5+
elif command -v python3 >/dev/null 2>&1; then
6+
exec python3 "$0" "$@"
7+
else
8+
echo "Error: neither python nor python3 was found in PATH" >&2
9+
exit 127
10+
fi
11+
":"""
212

313
# This script processses $WM_PRJECT_VERSION and outputs the result to
414
# foamVersion4wmles.H

0 commit comments

Comments
 (0)