add Makefile with build-relayer-contracts task

This commit is contained in:
Andrea Franz 2020-06-23 15:52:35 +02:00
parent 3ee7293a84
commit 6a93ad468b
No known key found for this signature in database
GPG Key ID: 4F0D2F2D9DE7F29D
3 changed files with 25 additions and 0 deletions

10
Makefile Normal file
View File

@ -0,0 +1,10 @@
CONTRACTS_PATH=./contracts
RELAYER_CONTRACTS_PATH=$$(realpath ./scripts/contracts)
build-relayer-contracts:
rm -rf $(RELAYER_CONTRACTS_PATH); \
yarn run solcjs -o $(RELAYER_CONTRACTS_PATH) --bin --abi $$(find $(CONTRACTS_PATH) -name *.sol); \
for fileName in $$(ls $(RELAYER_CONTRACTS_PATH)); do \
newName=$${fileName##*_}; \
mv $(RELAYER_CONTRACTS_PATH)/$${fileName} $(RELAYER_CONTRACTS_PATH)/$${newName}; \
done;

View File

@ -37,6 +37,7 @@
"react-scripts": "3.4.1",
"redux": "^4.0.5",
"redux-thunk": "^2.3.0",
"solc": "^0.6.10",
"typeface-roboto": "^0.0.75",
"typescript": "^3.8.3",
"web3": "^1.2.7",

View File

@ -15373,6 +15373,20 @@ solc@^0.6.0:
semver "^5.5.0"
tmp "0.0.33"
solc@^0.6.10:
version "0.6.10"
resolved "https://registry.yarnpkg.com/solc/-/solc-0.6.10.tgz#6e45b4f7013c7098fc1e31f7d86ce949e8c49e18"
integrity sha512-+oHwIvNjg3bxXvL9yua/Z4ZFEdkCkgRSh7aIGGb+mf/gzoA8PRKiKGYDsjMaj0CJLH1BTBOUpNFeYhhnUFfjRg==
dependencies:
command-exists "^1.2.8"
commander "3.0.2"
fs-extra "^0.30.0"
js-sha3 "0.8.0"
memorystream "^0.3.1"
require-from-string "^2.0.0"
semver "^5.5.0"
tmp "0.0.33"
solidity-parser-antlr@0.4.5:
version "0.4.5"
resolved "https://registry.yarnpkg.com/solidity-parser-antlr/-/solidity-parser-antlr-0.4.5.tgz#4de1867f1a12df4553886209225bc80328aeb0c1"