Skip to content

Commit 11e2281

Browse files
committed
Removed bash-isms.
1 parent 649d1ca commit 11e2281

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

RegistryProcessor/generate-modules

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,21 +6,23 @@ MODDIR="$OUTDIR/Graphics/Rendering/OpenGL/Raw"
66
REGISTRY="OpenGL-Registry/gl.xml"
77
API="gl"
88

9-
function runconverter() {
9+
runconverter() {
1010
echo "running" $@ 1>&2
11-
cabal run -v0 -- "$REGISTRY" "--api=$API" $@
11+
cabal run -v0 -- "${REGISTRY}" "--api=$API" $@
1212
}
1313

14-
mkdir -p "$MODDIR"
14+
mkdir -p "${MODDIR}"
1515

16-
runconverter --print-tokens > "$MODDIR/Tokens.hs"
17-
runconverter --print-functions > "$MODDIR/Functions.hs"
16+
runconverter --print-tokens > "${MODDIR}/Tokens.hs"
17+
runconverter --print-functions > "${MODDIR}/Functions.hs"
1818

1919
for i in 1.0 1.1 1.2 1.3 1.4 1.5 2.0 2.1; do
20-
runconverter --print-feature --version=$i --profile=version > "$MODDIR/Version"${i/\./}.hs
20+
VER=`echo $i | sed 's/\.//'`
21+
runconverter --print-feature --version=$i --profile=version > "${MODDIR}/Version${VER}.hs"
2122
done
2223

2324
for i in 3.0 3.1 3.2 3.3 4.0 4.1 4.2 4.3 4.4 4.5; do
24-
runconverter --print-feature --version=$i --profile=core > "$MODDIR/Core"${i/\./}.hs
25-
runconverter --print-feature --version=$i --profile=compatibility > "$MODDIR/Compatibility"${i/\./}.hs
25+
VER=`echo $i | sed 's/\.//'`
26+
runconverter --print-feature --version=$i --profile=core > "${MODDIR}/Core${VER}.hs"
27+
runconverter --print-feature --version=$i --profile=compatibility > "${MODDIR}/Compatibility${VER}.hs"
2628
done

0 commit comments

Comments
 (0)