From 310b5d56c8d17583768093fa8373e866fd5e480c Mon Sep 17 00:00:00 2001 From: Tanuj Soni Date: Mon, 12 Mar 2018 17:03:21 +0530 Subject: [PATCH 1/4] [RAFFLE-794] Uploadable app --- initfile.json | 12 ++++++++++++ package.json | 2 +- public/index.html | 2 +- scripts/create-metadata.js | 2 +- 4 files changed, 15 insertions(+), 3 deletions(-) create mode 100644 initfile.json diff --git a/initfile.json b/initfile.json new file mode 100644 index 0000000..07362ac --- /dev/null +++ b/initfile.json @@ -0,0 +1,12 @@ +{ + "raffle": { + "contractName": "Raffle", + "contractFilename": "contracts/Raffle.sol", + "args": { + "_name": "New", + "_ticketCount": 5, + "_ticketPrice": 50, + "_charityPercentage": 60 + } + } +} \ No newline at end of file diff --git a/package.json b/package.json index 9470cdf..9a2fa2e 100644 --- a/package.json +++ b/package.json @@ -28,7 +28,7 @@ "scripts": { "start": "npm-run-all -p watch-css start-js", "start-js": "react-scripts start", - "build": "npm run build-css && react-scripts build && mkdir package && mkdir package/contracts && node scripts/create-metadata.js && mv build/* package/ && cd package && zip -r app.zip * && cd .. && rm -rf build && mv package build", + "build": "npm run build-css && react-scripts build && node scripts/create-metadata.js && cp -a lib/lottery/contracts/ ./build/ && cp initfile.json ./build/", "test": "react-scripts test --env=jsdom", "eject": "react-scripts eject", "build-css": "node-sass-chokidar src/ -o src/", diff --git a/public/index.html b/public/index.html index 2e47286..81c5edb 100644 --- a/public/index.html +++ b/public/index.html @@ -14,7 +14,7 @@ - +