/v1-core

P⛰️rter C⛰️re

Primary LanguageTypeScriptGNU Affero General Public License v3.0AGPL-3.0

Porter Smart Contracts Porter Smart Contracts

app docs discord blog twitter

V1

Smart Contracts powering the Porter protocol.

Development

For local development there are environment variables necessary to enable some hardhat plugins.

Deployment

Using hardhat-deploy all of the scripts in the ./deploy folder are run.

Deploying to rinkeby

npx hardhat deploy --network rinkeby

Verification

Verify deployed contracts with hardhat-etherscan.

npx hardhat verify <address>

Testing

Running the hardhat test suite

npx hardhat test

Fork testing requires first running the mainnet-fork

npx hardhat node

and making the target for testing the local node

npx hardhat test --network localhost

Running the fuzzing test suite with Echidna

Other useful commands

npx hardhat help
npx hardhat compile # create contract artifacts
npx hardhat clean # removes artifacts and maybe other things
npx hardhat coverage # runs the contract coverage report
npx hardhat integration # runs the integration task
npx eslint '**/*.{js,ts}' --fix
npx prettier '**/*.{json,sol,md,ts}' --write
npx solhint 'contracts/**/*.sol' --fix