diff options
author | truebrain <truebrain@openttd.org> | 2011-11-29 23:29:12 +0000 |
---|---|---|
committer | truebrain <truebrain@openttd.org> | 2011-11-29 23:29:12 +0000 |
commit | e60747a6043d42b872d02ba667f99187b5d3f1d7 (patch) | |
tree | bbbbba1911433b50caefb261b0d25a78d6b825ba | |
parent | 549e072041b06d72f7c832f94e609222045ccd13 (diff) | |
download | openttd-e60747a6043d42b872d02ba667f99187b5d3f1d7.tar.xz |
(svn r23372) -Move: move squirrel export script to script/api/
-rw-r--r-- | src/script/api/squirrel_export.awk (renamed from src/ai/api/squirrel_export.awk) | 0 | ||||
-rwxr-xr-x | src/script/api/squirrel_export.sh (renamed from src/ai/api/squirrel_export.sh) | 5 |
2 files changed, 3 insertions, 2 deletions
diff --git a/src/ai/api/squirrel_export.awk b/src/script/api/squirrel_export.awk index 56d5ee1b3..56d5ee1b3 100644 --- a/src/ai/api/squirrel_export.awk +++ b/src/script/api/squirrel_export.awk diff --git a/src/ai/api/squirrel_export.sh b/src/script/api/squirrel_export.sh index 891a522d7..b29727a7d 100755 --- a/src/ai/api/squirrel_export.sh +++ b/src/script/api/squirrel_export.sh @@ -21,6 +21,7 @@ if [ "$?" != "0" ]; then fi # This must be called from within a src/???/api directory. +scriptdir=`dirname $0` apilc=`pwd | sed "s@/api@@;s@.*/@@"` apiuc=`echo ${apilc} | tr [a-z] [A-Z]` @@ -31,7 +32,7 @@ if [ -z "$1" ]; then # ScriptController has custom code, and should not be generated if [ "`basename ${f}`" = "script_controller.hpp" ]; then continue; fi - ${AWK} -v api=${apiuc} -f squirrel_export.awk ${f} > ${bf}.tmp + ${AWK} -v api=${apiuc} -f ${scriptdir}/squirrel_export.awk ${f} > ${bf}.tmp if [ "`wc -l ${bf}.tmp | cut -d\ -f1`" = "0" ]; then if [ -f "${bf}.sq" ]; then @@ -50,7 +51,7 @@ if [ -z "$1" ]; then fi done else - ${AWK} -v api=${apiuc} -f squirrel_export.awk $1 > $1.tmp + ${AWK} -v api=${apiuc} -f ${scriptdir}/squirrel_export.awk $1 > $1.tmp if [ `wc -l $1.tmp | cut -d\ -f1` -eq "0" ]; then if [ -f "$1.sq" ]; then echo "Deleted: $1.sq" |