diff options
Diffstat (limited to 'games-strategy/ja2-stracciatella/files/ja2-convert.sh')
-rw-r--r-- | games-strategy/ja2-stracciatella/files/ja2-convert.sh | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/games-strategy/ja2-stracciatella/files/ja2-convert.sh b/games-strategy/ja2-stracciatella/files/ja2-convert.sh new file mode 100644 index 000000000000..4f337ca75351 --- /dev/null +++ b/games-strategy/ja2-stracciatella/files/ja2-convert.sh @@ -0,0 +1,16 @@ +#!/bin/sh +# Convert names of data-files to lower-case + +# location of the data-files +GAMES_DATADIR=@GAMES_DATADIR@ + +cd "${GAMES_DATADIR}" || exit 1 + +# convert to lowercase +find . -exec sh -c 'echo "${1}" +lower="`echo "${1}" | tr [:upper:] [:lower:]`" +[ -d `dirname "${lower}"` ] || mkdir `dirname ${lower}` +[ "${1}" = "${lower}" ] || mv "${1}" "${lower}"' - {} \; + +# remove leftover +rm -r ./TILECACHE ./STSOUNDS |