who doesn't like losing money
This project was bootstrapped with Truffle.
npm install -g truffle
truffle unbox react
origin/master
4-feature
).add functionality xyz (#4)
origin/master
into your local branchmaster
and push the changesonetime setup
git clone https://github.com/alexscheitlin/lottery-dapp
# or
git clone git@github.com:alexscheitlin/lottery-dapp
cd lottery-dapp/client/
npm install
Detailed information can be found here: README.
npm install -g truffle
# or
sudo npm install -g truffle
Install with @beta
to get the latest updates which fixes a bug that caused wrong gas estimations (more details).
npm install -g ganache-cli@beta
# or
sudo npm install -g ganache-cli@beta
ganache-cli
in a terminal - which will most likely be running on: http://127.0.0.1:8545
).Metamask
in your browser and login with your wallet.RPC Server
of ganache-cli
into the New RPC URL field.ganache-cli
an copy one of the private keys.Metamask
, click on the colored circle on the top right and select Import Account.ganache-cli
and hit Import. You should now be logged in with an Account from the ganache-cli
network with a balance of 100 ETH.everytime to run the environment
# Terminal Tab #1
cd /path/to/lottery-dapp
git pull
ganache-cli
.Smart Contracts
:
# Terminal Tab #1
truffle compile
Smart Contracts
on the Ganache
network:
# Terminal Tab #1
truffle migrate --reset
Truffle
console:
# Terminal Tab #1
truffle console
React
client:
# Terminal Tab #2
cd /path/to/lottery-dapp/client
npm install
npm start
localhost:3000
should be opened automatically in your browser:warning: Make sure your Metamask is connected to the correct network! :warning: