Skip to content

Commit

Permalink
fixed build script to work with it's directory as the working directory
Browse files Browse the repository at this point in the history
  • Loading branch information
cjbell630 committed Apr 9, 2021
1 parent add7420 commit 6d95644
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions build/scripts/compile-reduce.sh
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
cd ../src || exit
cd ../../src || exit
cp ../build/scripts/amalg.lua ./ # copy bc amalg.lua and main.lua + dependencies must be in same dir for line 4

lua -lamalg main.lua # generate require map cache for amalg.lua
./amalg.lua -o merged.lua -s main.lua -c # merge all files into one
rm -rf amalg.cache
rm -rf amalg.lua # remove copy
rm -rf amalg.lua # remove copy

../build/scripts/luasrcdiet.lua --maximum -o reduced.lua merged.lua # reduce file
rm -rf merged.lua # remove non-reduced file
mv reduced.lua ../build/yoshi-nes-ai.lua # move and rename
rm -rf merged.lua # remove non-reduced file
mv reduced.lua ../build/yoshi-nes-ai.lua # move and rename
exit

0 comments on commit 6d95644

Please sign in to comment.