Skip to content

Commit

Permalink
fix: change directory back before retrieving constants
Browse files Browse the repository at this point in the history
  • Loading branch information
stephenctw committed Nov 29, 2023
1 parent 72166ca commit 89e0717
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions helper_scripts/generate_UArchConstants.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,17 +17,18 @@ t=`tail -n -$last $TEMPLATE_FILE`

cd $EMULATOR_DIR
make build-debian-image
cd -

# run the Lua script that instantiates the cartesi module and
# run the Lua script that instantiates the cartesi module and
# outputs the uarch constants values
constants=$(docker run \
constants=$(docker run --rm \
-v`pwd`:/opt/cartesi/machine-solidity-step \
-w /opt/cartesi/machine-solidity-step \
-it cartesi/machine-emulator:devel \
cartesi/machine-emulator:devel \
/opt/cartesi/machine-solidity-step/helper_scripts/generate_UArchConstants.lua)

# compose the solidity file from all components
echo -e "$h" "\n\n$constants" > $TARGET_FILE
echo -e "$t" >> $TARGET_FILE

echo "wrote $TARGET_FILE"
echo "wrote $TARGET_FILE"

0 comments on commit 89e0717

Please sign in to comment.