This project is using Hardhat for development, compiling, testing and deploying. The development tool used for development is Visual Studio Code which has great plugins for solidity development and mocha testing.
-
Binance Chain
- PSI : 0x6e70194F3A2D1D0a917C2575B7e33cF710718a17
- PSIV1 : 0x9A5d9c681Db43D9863e9279c800A39449B7e1d6f
- Income : 0xDc3890618bd71d3eF3eC18BB14a510c0dA528947
- PSI Governance : 0xa1B540B2BE89b55d5949754E326Fb80063F9781f
- Fee Aggregator : 0xE431399b0FD372DF941CF5e23DBa9FC9Ad605FeF
-
Binance Test Chain
- PSI : 0x6C31B672AB6B4D455608b33A11311cd1C9BdBA1C
- PSIV1 : 0x066Bd99080eC62FE0E28bA687A53aC00794c17b6
- Income : 0x75d8b48342149ff7F7f1786e6f8B839Ca669e4cf
- PSI Governance : 0x04A31EEF89095Eb131Cb1b48bb3ab87655e5e681
- Fee Aggregator : 0xdA56896De5A1aF4E3f32c0e8A8b8A06Ca90CB50c
-
Polygon
-
Polygon mumbai
- Simple Fee Aggregator : 0x12d181455C792C6a26a78823dB55c1aDDD3AC910
-
Mainnet
-
Kovan
Introduction to compiling these contracts
npm install or yarn install
npx hardhat compile
npx hardhat test
This is needed before a truffle migrate to the development network. You can also use this for local development with for example metamask. Hardhat node guide
npx hardhat node
Use the scripts in the "scripts" folder. Each script has the command to start it on top.
Make sure you have set the right settings in your '.env' file. You have to create this file with the following contents yourself:
BSC_PRIVATE_KEY=<private_key>
BSC_TEST_PRIVATE_KEY=<private_key>
KOVAN_PRIVATE_KEY=<private_key>
RINKEBY_PRIVATE_KEY=<private_key>
GOERLI_PRIVATE_KEY=<private_key>
MAIN_PRIVATE_KEY=<private_key>
KOVAN_INFURA=https://kovan.infura.io/v3/<infura_key>
RINKEBY_INFURA=https://rinkeby.infura.io/v3/<infura_key>
GOERLI_INFURA=https://goerli.infura.io/v3/<infura_key>
MAIN_INFURA=https://mainnet.infura.io/v3/<infura_key>
MAIN_ALCHEMY_URL=https://eth-mainnet.alchemyapi.io/v2/<alchemy_key>
KOVAN_ALCHEMY_URL=https://eth-kovan.alchemyapi.io/v2/<alchemy_key>
ETHERSCAN_API_TOKEN=<etherscan_api_token>
BSC_API_TOKEN=<bscscan_api_token>
npx hardhat flatten contracts/DPexRouter.sol > contracts-flattened/DPexRouter.sol