Smart Contract for creating a Lottery that maps an address with a username
@TODO -> Add funds and enable liquidity
Installation :
-
Install Brownie :
pip install eth-brownie
- Install ChainLink Dependencies
git clone https://github.com/PatrickAlphaC/chainlink-mix
cd chainlink-mix
brownie bake chainlink-mix
cd chainlink-mix
pip install -r requirements.txt
Set WEB3_INFURA_PROJECT_ID
, and PRIVATE_KEY
=> Infura.
export WEB3_INFURA_PROJECT_ID=<PROJECT_ID>
export PRIVATE_KEY=<PRIVATE_KEY>
AND THEN RUN source .env
npm install -g ganache-cli
and then :
brownie networks add Ethereum ganache host=http://localhost:8545 chainid=1337
brownie run scripts/1_deploy_lottery.py
brownie run scripts/2_start_lottery.py
brownie run scripts/3_enter_lottery.py
brownie run scripts/4_end_lottery.py
brownie test
brownie test --network <network>
brownie test
brownie test --network mainnet-fork