diff --git a/inject_version.sh b/inject_version.sh index c0ff92d..37aa1df 100755 --- a/inject_version.sh +++ b/inject_version.sh @@ -1,7 +1,7 @@ #!/bin/sh -if [ ! TRAVIS_TAG ]; then - sed -i "s/define config.version = \"0.1.2\"/define config.version = \"$TRAVIS_COMMIT\"/g" mod/game/options.rpy; +if [ ! -z TRAVIS_TAG ]; then + sed -i "s/config.version = \"0.1.2\"/config.version = \"$TRAVIS_COMMIT\"/g" mod/game/options.rpy; cat mod/game/options.rpy | grep config.version; else sed -i "s/define config.version = \"0.1.2\"/define config.version = \"$TRAVIS_TAG\"/g" mod/game/options.rpy;